New answers tagged

0

Why doesn't it work? The error messages /usr/lib/passmgmt: Password file(s) busy. Try again later /usr/lib/passmgmt: Password file(s) busy. Try again later /usr/lib/passmgmt: Password file(s) busy. Try again later likely mean you don't have permission to create a file in /etc. The only source of that error message that I can find is in the passmgmt ...


1

As iconv was complaining about the en_GB.ISO8859-15 locale, I thought i would try the more generic "C" in its place. export LC_ALL=C This allowed the command to get past the error and create a timezone listing. I Suspect the problem with using en_GB.ISO8859-15 is to do with iconv not understanding or liking certain characters or layouts.


4

The problem you're having is with the for unitcaseno in `cat /pims/nigel/UNLOAD-DB/xaa` structure. This will split the file into words, not lines. This is why you see String = 349702 in the output; you're only seeing the first word and not the whole line. Instead consider a loop similar to while read unitcaseno do .... done < /pims/nigel/UNLOAD-...


0

try function print() { for i in $InsertFile1 do cat $i done > Script.sh echo "Exit--------------------------0" >> Script.sh } you may wish to skip line with echo Exit if $Insertfile1 have only one value, script could be further simplified function print() { cp $Inserfile Script.sh echo "Exit--------------------...


1

Basically you have to use pre-internet methods to transfer over a serial tty, and you must have a way to receive the transfer on the other side. Obviously the best way to do this is by using ZMODEM, which means you need to have a tool like sz already on the receiving end. However this isn't always possible, for example, when the receiving target is a router ...


2

The following gawk program should work for you: echo -e "unixtime;host_name;ip_adress;description;2;0;1\n1234567890;hName;hIP;hDesc;2;1;0" | gawk -F";" 'BEGIN {OFS=";"} { if (NR<2) next; $1=strftime("%Y-%m-%d %H:%M:%S", $1); $5=($5==2?"CRITICAL":$5); $6=($6?"Yes":"No") ; $7=($7?"Yes":"No") ; print}' 2009-02-14 00:31:30;hName;hIP;hDesc;CRITICAL;...


2

On Linux the ps command detects whether the output is to a terminal or not. If it is to a terminal then it truncates the output to the terminal width. If it is not on a terminal then it doesn't truncate. Effectively it behaves as if it automatically adds the ww flags. You can see the difference by typing ps aux and ps aux | cat In your example you are ...


3

You are using non standard BSD options, whether under Linux or Solaris. The portable way is to use the -o option to specify which fields you want to appear, here for example ps -o pid,args. Note that unless you are using a recent 11.3 update or newer, the argument list will be limited to 80 characters unless you are root or own the process. Alternatively, ...


7

To select only the SSE flags, try: awk '/SSE/' ORS=' ' RS=' ' The key thing here is setting the record separators on input and output to a space. That way, each option is accepted or rejected separately. For example: $ SUNCC_CXXFLAGS="-D__SSE2__ -D__SSE3__ -D__SSSE3__ -D__SSE4_1__ -D__SSE4_2__ -D__AES__ -D__PCLMUL__ ..." $ newFLAGS="$(echo "$...


0

I have the solution that works on Sun Solaris. This will zip up 10000 files per each multipart zip and scp the master zip to the remote server. #!/usr/bin/env bash # #------------------------------------------------------------ #-- Zip up content files based on $1 parameter #------------------------------------------------------------ function zip_files { ...


3

In Solaris 10 there are no repositories. You do have patch bundles (available under support contracts) that include all the patches. Alternativaly you might use smpatch. Software packages are provided as standalone and might have dependencies. Unfortunately with Solaris 10 package manager you need to solve these dependencies manually. With Solaris 11 you ...


0

cp -a is not quite equivalent to cp -pPR. In particular, at least in newer versions of Solaris, -a implies --preserve=all, while -p only preserves mode,ownership,timestamps. (--preserve=all also preserves additional attributes such as context,links,xattr). From a newer release of Solaris' man page: -a, --archive same as -dR --preserve=all



Top 50 recent answers are included