Search Results

Search: Posts Made By: BRH
2,245
Posted By BRH
Thanks Don, your solution is perfect! The...
Thanks Don, your solution is perfect!

The log files are pure unix. I'm familiar with the Linux grep '-A and -B' to find the lines leading and trailing the context of the matching lines. As far as...
2,245
Posted By BRH
Problem renaming files on Solaris 10 server
Good day all.

I'm trying to rename some files in my home directory with some bizarre results. Basically I need to change the IP address in the filename to the hostname which I ggrep from within...
1,113
Posted By BRH
How to remove a line based on contents of the first column?
Good day all.

Using basic UNIX/Linux tools, how would you delete a line based on a character found in column 1?

For example, if the CITY name contains an 'a' or 'A', delete the line:

New...
Forum: Solaris 01-29-2014
3,675
Posted By BRH
Thanks for your reply hicksd8. All the nodes...
Thanks for your reply hicksd8.

All the nodes in my cluster have the same disk configuration. This is what it looked like about a week before the problem arose:
Volume Size ...
Forum: Solaris 01-29-2014
3,675
Posted By BRH
Thanks for your prompt reply, bartus11! #...
Thanks for your prompt reply, bartus11!

# raidctl -S
2 "LSI_1064"
c2t0d0 2 0.2.0 0.5.0 1 DEGRADED
c2t1d0 2 0.1.0 0.3.0 1 OPTIMAL
0.1.0 GOOD
0.2.0 GOOD
0.3.0 GOOD
0.5.0 FAILED
Forum: Solaris 01-29-2014
3,675
Posted By BRH
Need assistance to replace root disk on Netra X4200
Good day.

I have a SUN Netra X4200 running on Solaris 10, with two disks in raid 1 configuration. HDD0 (c2t0d0) seems to have a problem but HDD1 (c2t1d0) is ok:
# for a in c2t0d0 c2t1d0 ; do...
2,123
Posted By BRH
I guess I forgot the 8, this being an example. ...
I guess I forgot the 8, this being an example. Also I'm not sure of the order yet, but if I can get an idea as to how to stream the order to a single line, I'd be very grateful.

Thanks,
Bjoern
2,123
Posted By BRH
Thanks for the replies, Joey, Corona. However,...
Thanks for the replies, Joey, Corona. However, you missed the last part of the challenge: the order of the parameters has to change as well.

Regards,
Bjoern
2,123
Posted By BRH
Need help parsing data with sed and/or nawk
Good day all.

I have the following entries of data in a file in a column, however, I need this data written on a single line with several parameters in a different order.

Current format:...
2,082
Posted By BRH
Virtual CDROM refuses to quit
Good day.

I have a Sun Netra X4200 M2 server with AMI BIOS. When I performed a iostat -En, I noticed that the AMI Virtual CDROM had taken device id c0t0d0, however, I need c0t0d0 for the real...
2,419
Posted By BRH
Bingo! Thanks a lot citaylor. I thought that...
Bingo! Thanks a lot citaylor. I thought that all the ^M had already been removed.

Thanks.
2,419
Posted By BRH
Thanks citaylor. Your solution worked on...
Thanks citaylor.

Your solution worked on some files and not others. I ran the commands in debug mode and substituted 'mv' for 'echo' to see what was happening.:
+ read fname
++ tail -1...
2,419
Posted By BRH
Need to rename file based on name in same file
Good day.

I need a one-liner (if possible) otherwise a longer script to do the following:

I have a list of files in a directory with the same filename extension, ie.

firstfile.cks,...
6,014
Posted By BRH
Thanks for the reply, Corona. It doesn't take an...
Thanks for the reply, Corona. It doesn't take an underscore either.

Bjoern

---------- Post updated at 02:15 PM ---------- Previous update was at 01:56 PM ----------


Furthermore,...
6,014
Posted By BRH
Problem with useradd, -p option in Solaris 10
Good day all.

I'm trying to add a user with useradd and the -p option to assign a project name, but the result is that the user is created with an error message: "UX: useradd: user.root name...
2,854
Posted By BRH
Thanks for your reply, but nope and nope. ...
Thanks for your reply, but nope and nope.

Regards,
BRH

---------- Post updated at 05:05 PM ---------- Previous update was at 04:52 PM ----------


Hi Dan.
My mistake, /usr/xpg4/bin/grep...
2,854
Posted By BRH
HI dan, no luck with this one either, it didn't...
HI dan, no luck with this one either, it didn't complain, but it did nothing.

Regards,
BRH
2,854
Posted By BRH
Hi danmero, which grep are you using, I'm on a...
Hi danmero, which grep are you using, I'm on a Solaris 10 system:

/usr/bin/grep -vf defaultRules rules.txt
/usr/bin/grep: illegal option -- f
Usage: grep -hblcnsviw pattern file . . .

...
2,854
Posted By BRH
Need a script or one-liner to purge lines from a file.
i all.

This one sounds so simple, but I can't get it to work. I need to delete lines with certain keywords from a file.

I have a file called defaultRules, with keywords:


IPSEC_AH
IKE_UDP...
4,724
Posted By BRH
Tyler, you made my day!:D The last method...
Tyler, you made my day!:D The last method without piping or redirection is what I was looking for.

Thanks so much,

Bjoern
4,724
Posted By BRH
Thanks tyler, it works now! # ./procheck ...
Thanks tyler, it works now!

# ./procheck
processName Status Node-1 Status Node-2
----------- ------------------- -------------------
tzMgmt ...
4,724
Posted By BRH
Hi editaguy. I don't think the problem's with...
Hi editaguy. I don't think the problem's with sed:


# sed '/ceName:.*/d; s/^[^:]*: //' 3rdline.txt | sed 'N;N;N;s/\n/\\t/g; s/\([^\\t]*\\t\)//3'...
4,724
Posted By BRH
Thanks for your efforts, edidataguy. However,...
Thanks for your efforts, edidataguy. However, the result is the following:

sed '/ceName:.*/d; s/^[^:]*: //' 3rdline.txt | sed 'N;N;N;s/\n/\t/g; s/\(^[^\t]*\t[^\t]*\t\)[^\t]*\t\([^\t]*\)$/\1\2/'...
4,724
Posted By BRH
Thanks for the reply, but the text you put into...
Thanks for the reply, but the text you put into [code - /code] is not really code but text.

Regards,

Bjoern
4,724
Posted By BRH
How do I create an array from a file using every 3rd line
A file contains the following information shown below. Every ceName has 2 consecutive lines that have to be evaluated, using awk, sed, cut (any common unix tools).

Input file:
ceName: Node-1...
Showing results 1 to 25 of 25

 
All times are GMT -4. The time now is 06:30 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy