10 More Discussions You Might Find Interesting
1. Solaris
Hi all, I'm using to Solaris machine. When I run a simple script this messenger come out:"limit: stacksize: Can't remove limit". Any one know the way to resolve this problem without reboot the machine?
Thanks in advance. (3 Replies)
Discussion started by: Diabolist9
3 Replies
2. UNIX for Advanced & Expert Users
I want to check the mail attachement size before sending the mail.
I coded:
IF FILESIZE > XBYTES THEN
MESSAGE "Mail attachment size exceeds limit"
ELSE
SEND MAIL.
But I want to know the quantifier.
To get the XBYTES, I used
ls -ltr filename | awk '{print $5}'
into a variable, now,... (1 Reply)
Discussion started by: harishkumardola
1 Replies
3. Shell Programming and Scripting
Hi,
I want to check file size in unix, based on file size I am going to execute appropriate command.
I tried below, but getting the error.
System details –
Machine hardware: sun4u
OS version: 5.9
if ( -s $f1 ) then
echo "filename exists and is > 0 bytes"
else
echo "filename... (7 Replies)
Discussion started by: rahulbahulekar
7 Replies
4. Shell Programming and Scripting
Hi,
I need help in writing unix script for checking space of some directories on the system and also send an email when it reaches the threshold limit.
I have written the followng code;
#!/bin/ksh
ADMIN="me@somewhere.com"
# set alert level 80% is default
THRESHOLD=80
df | grep -E... (5 Replies)
Discussion started by: jmathew99
5 Replies
5. Shell Programming and Scripting
Hello,
I have a script that should store file size in a variable $filesize.
I don't know what is the best way to do it.
I tried
ls -lt myfile.txt | sed something >$filesize
but I don't know how to use sed to get filesize. I know that the owner of the file is root and then we have some... (6 Replies)
Discussion started by: pppswing
6 Replies
6. Shell Programming and Scripting
I want to know if there is any unix command to view the size of the file?
eg.
i have a directory letter
in this i have file a,b,c,d,e.
i just want to know the size of file d and not any other. (3 Replies)
Discussion started by: infyanurag
3 Replies
7. UNIX for Dummies Questions & Answers
Hey guys.
What I need to do is this:
I need to find files that have a certain filesize (for this case a file size of 0 (zero) )
When I find this file with a filesize of zero I need to echo a statement that tells the user to delete it and not to delete it if the filesize is greater than... (3 Replies)
Discussion started by: ndoggy020
3 Replies
8. Shell Programming and Scripting
Hello everybody it's me again.
I have a procces that is writing in a 'file1' automatically but i want to truncate 'file1' to a filesize 'x' that mean if the 'file1' size is 'x' i want to delete the first lines while the last lines are being writed, that have sence?
in the process are an... (1 Reply)
Discussion started by: Lestat
1 Replies
9. Shell Programming and Scripting
How do I identify if there is any content in a file?
If there is nothing in a specified file, I'd like to send an email indicating that there is nothing to report.
Any help appreciated. (3 Replies)
Discussion started by: Cameron
3 Replies
10. Shell Programming and Scripting
I know in php if you use the function filesize it will return the size of the file in bytes, but is there an easy way to get the size in MB.
Cheers (2 Replies)
Discussion started by: jmg5
2 Replies