while var not empty


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting while var not empty
# 1  
Old 03-11-2009
while var not empty

Hi!

How can I run a cicle while one var is not empty?
Or better saying how can I see if the var has something?

thanks
# 2  
Old 03-11-2009
test -n
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Transfer the logs being thrown into /var/log/messages into another file example /var/log/volumelog

I have been searching and reading about syslog. I would like to know how to Transfer the logs being thrown into /var/log/messages into another file example /var/log/volumelog. tail -f /var/log/messages dblogger: msg_to_dbrow: no logtype using missing dblogger: msg_to_dbrow_str: val ==... (2 Replies)
Discussion started by: kenshinhimura
2 Replies

2. Shell Programming and Scripting

Csh , how to set var value into new var, in short string concatenation

i try to find way to make string concatenation in csh ( sorry this is what i have ) so i found out i can't do : set string_buff = "" foreach line("`cat $source_dir/$f`") $string_buff = string_buff $line end how can i do string concatenation? (1 Reply)
Discussion started by: umen
1 Replies

3. Solaris

/var/adm/messages empty

Hi all, One of the server is showing empty messages # logger -p user.error HELLO_SYSLOGD # dmesg Mon Apr 23 15:11:19 MYT 2012 /etc/syslog.conf file, i tried copy the conf file from another server, still it is not working *.err;kern.notice;auth.notice /dev/sysmsg... (8 Replies)
Discussion started by: beginningDBA
8 Replies

4. Solaris

Difference between /var/log/syslog and /var/adm/messages

Hi, Is the contents in /var/log/syslog and /var/adm/messages are same?? Regards (3 Replies)
Discussion started by: vks47
3 Replies

5. Cybersecurity

/var/log/secure* mysteriously empty!

Hello everyone. I'm a newbie and this is my first post, and I'm hoping to get some help understanding what happened on my server. I did as much research as I could, but now I turn to the forums for help :) I've set up a VPS server and I "thought" I had good enough security on it, but all of a... (2 Replies)
Discussion started by: antondev
2 Replies

6. Solaris

/var/adm & /var/sadm

what is the difference between tha /var/adm and /var/sadm files in solaris 10 Os please can any one respond quickly thanking you (2 Replies)
Discussion started by: wkbn86
2 Replies

7. UNIX for Dummies Questions & Answers

Check to see if string var is empty

i have a veriable set var1 set var2 = abcd how can i check if var 1 is empty and if var 2 is not empty ??? (2 Replies)
Discussion started by: nirnir26
2 Replies

8. Solaris

/var/adm/meesages file empty

Do not know the reason y messages file is empty already restarted the syslog daemon but still its showing empty . xxxxxxx# more /var/adm/messages xxxxxx# # ps -efo zone,pid,ppid,time,comm | grep syslog | grep global global 11861 1 00:10 /usr/sbin/syslogd svcs... (2 Replies)
Discussion started by: fugitive
2 Replies

9. Solaris

diff b/w /var/log/syslog and /var/adm/messages

hi sirs can u tell the difference between /var/log/syslogs and /var/adm/messages in my working place i am having two servers. in one servers messages file is empty and syslog file is going on increasing.. and in another servers message file is going on increasing but syslog file is... (2 Replies)
Discussion started by: tv.praveenkumar
2 Replies

10. UNIX for Dummies Questions & Answers

Getting same exit status for empty and non empty file

Hi All, I am checking for a empty input file to do some further action , but I am getting exit status 0 in both the cases , for empty and non empty file both. The value of $? is coming 0 in if part also and else part too. #!/bin/ksh if ]; then echo "data" # exit 0 echo "$?" else... (4 Replies)
Discussion started by: mavesum
4 Replies
Login or Register to Ask a Question