xfs failed

i am running red hat linux 7.2
my hard drive was full thats why xfs failed.to make space on my drive i deleted the contents of /tmp which is necessary for x server to start .
what can i do now???
i cant start linux in gui mode.
Who is Participating?
GnsConnect With a Mentor Commented:
How did you remove it?
Did you do
rm -rf /tmp
or ...?
If you did, first make sure you have /tmp with
ls -l /
If not, then create it with
mkdir /tmp
Then set the access rights for it with
chmod 1777 /tmp
When done, a "ls -l /" should show a line like
drwxrwxrwt   13 root     root         1024 feb 27 04:02 tmp
for /tmp.
You also might need to do this for /tmp/.X11-unix ... but that directory should be created by X automagically... anyway, here it is:
mkdir /tmp/.X11-unix
chmod 1777 /tmp/.X11-unix

Check that X is OK with
X -probeonly

All the above should be performed logged on as root.
When done, either reboot or "flip-flop" runlevel from 5 to 3 and back:
telinit 3
telinit 5

-- Glenn
itfreakAuthor Commented:
i created /tmp /tmp.X11-unix with the specified permissions but it is not working.
i removed /tmp usin the command
rm -r /tmp
Hmmm... Ah, you might need to do the (exact) same for /tmp/.font-unix and /tmp/ICE-unix, although these should be autocreated too...

Might it be that you crashed horribly after the removal of /tmp, so that the subsystem "lockfiles" didn't get cleaned up?

/tmp is needed by both X and xfs, since it usually hold the "socket handle" (a pseudo-file) used for communication between a local xfs and X. If xfs wont start, chances are very great that X will die because it cannot open the socket.

First check that xfs really isn't running with
ps auxww | grep xfs | grep -v grep<Enter>
/etc/init.d/xfs status<Enter>

If it isn't running, check that you don't have a "dangling" lockfile for xfs with
ls -l /var/lock/subsys/xfs<Enter>
and if you do, remove it with
rm /var/lock/subsys/xfs<Enter>
Then start xfs with
/etc/init.d/xfs start<Enter>
If that goes OK do
telinit 3<Enter>
telinit 5<Enter>

and you should be fine...
If not, we'll have to start looking at specific error messages from first xfs and then X, but let's save that for later:-)

-- Glenn
Build your data science skills into a career

Are you ready to take your data science career to the next step, or break into data science? With Springboard’s Data Science Career Track, you’ll master data science topics, have personalized career guidance, weekly calls with a data science expert, and a job guarantee.

/tmp/ICE-unix should be /tmp/.ICE-unix

-- Glenn (a.k.a. Le Grand Typo)
Like Gns wrote, do "rm -rf /tmp", "mkdir /tmp", "chmod 1777 /tmp" (ownership root.root). Do not leave anything in tmp.

Just a note: /tmp is the place for temporary files. Applications should not expect any file to survive in it when you turn your box off. So feel free to delete anything inside. There is probably somewhere in RH7.2 an option to clean it at every reboot.

Now if you can't reboot into X, could you have a look of what appears in your logs at start up: files messages (?)X.err (?) and boot.msg (?) in /var/log.
The only time I'd suggest /tmp to be more or less OK to "blindly" wipe is when you are in single useer mode. Caution is best otherwise.

-- Glenn
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.