Click to See Complete Forum and Search --> : Sun Solaris Disk Full and mail problem
JustTrowItIn
10-13-2000, 02:52 PM
Hi all. I'm very new to the Unix/Linux "non-micosoft" side of networking. I have a Sun Solaris firewall, and the mailbox for root is full. Now the disk is full. When I try to access the mailbox to delete the messages, I receive the error "mailer cannot open this mailbox". The mailbox is located in /var/mail/root. Please keep in mind when answering my question that I have an NT background and know very little about Unix. If you need anymore information, I will do my best to get it for you. Thanks all!
epseps
10-15-2000, 12:28 AM
hmmm...are you logged in as root? to check open up a terminal or console and type 'who am i'. if you are root then type 'cd /var/adm' then type 'ls -l'and check the permissions, you should see some thing like rw-r--r--. the first rw- is the root's permissions meaning you can read and write the mail folder. If by odd chance root does not have permissions then type 'chmod 644' and that should fix it.
JustTrowItIn
10-17-2000, 03:31 PM
I finally got a chance to try the recommended advice, and here are the results.
Yes I am logged in as root, just to verify this I typed who am I and received:
root pts/4 Oct 17...
I then went to the /var/adm directory and checked my permissions. Root does have the proper permissions (rw-r--r-- etc.)
Just for the hell of it I ran the chmod 644 command. Tried to access the mailbox, same error.
The disk is definitly full because of the full mailbox. Any idea of anything safe I can delete just to free up some space? Let me know if anyone has any ideas. Thanks!
Just Trow It In And See What Happens
epseps
10-18-2000, 12:38 AM
I'm stumped. I'll check at work tommorow. If you have access to Sun Tech support give them a call...I'm guessing now that all the unreadable mail that is filling up your mailbox may be being generated by the same thing that does not allow you read it...Hopefully I'll get some infor for you by tommorrow evening.
bytemare
10-18-2000, 09:30 AM
have you tried to delete the mbox?
if you try to "open" it, it will try to create some temporary file, and if the filesystem is full, you'll get an error. Just rm it.
JustTrowItIn
10-18-2000, 11:03 AM
How exactly do I delete just that mail box? After I delete it, will it automatically recreate itself when I try and access the mail? Thanks!
emanonii
10-18-2000, 11:26 AM
Write a null byte to it:
go to /var/mail and type:
:>root
That should make the file 0 bytes.
bytemare
10-18-2000, 11:57 AM
rm /var/mail/root
assuming that's where it is.
Then all of your mail is gone. when you start your mail program, it will at first create it at 0 bytes (or if root gets mail then it will be created but it won't be so big).
JustTrowItIn
10-18-2000, 04:06 PM
I used the :>root command from the /var/mail directory, and it worked. My disk is not longer full, and I can access the mail box. Thank you so much!
javierm
10-22-2000, 03:44 PM
Hi there-
If your /var filesystem is full, what I would
recommend is that you grow it with either
solstice disksuite or veritas volume manager.
Solstice is a free product that should be laying around. The idea is to concatenate the
/var file system with another unassigned partition making /var simply bigger.
By the way, directories need a 755 set of permissions to be able to access the directory. If /var is full, it could also be
the result of an out of control printing queue (check /var/spool/lp).
Later