in reply to Newbie regular expressions question

G'day bayareamonk,

Please use code tags for your data as well as your code.

You say you want to replace ip*internal (which is what I see but I'd guess that's supposed to be ip*[internal] because [internal] would generate that link). However, I don't see either of those forms in what you show as "looks like this", so I'm reduced to making more guesses.

You probably have one or more of these problems in your regex (/\ip*\internal/):

So, overall, my guess is that your substitution should look like this:

s/ip\*\[internal\]/ip-10.10.10.1-internal/

If you provide a clear picture of an input line, what output you expect and what output you're actually getting (along with any error or warning messages), we can probably provide a better answer. More information about what to post and how to post it, such that we can better help you, can be found in the "How do I post a question effectively?" guidelines.

Update: s/left brace/left bracket/ (in 3rd dot point)

-- Ken