LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 03-13-2006, 09:59 AM   #1
weibullguy
ReliaFree Maintainer
 
Registered: Aug 2004
Location: Kalamazoo, Michigan
Distribution: Slackware-current, Cross Linux from Scratch, Gentoo
Posts: 2,705
Blog Entries: 1

Rep: Reputation: 220Reputation: 220Reputation: 220
Unhappy Unclean Shutdown: X Libraries Reported As Missing on Reboot


I'm running Fedora 4. I had an unclean shutdown last night due to a power outage. The machine reboots into a terminal rather than to the graphical login screen that lists each user, allows one to choose which session they want to use, etc. I am able to login as a user and root. When I enter ‘startx’, I get a litany of missing library errors.

Here’s what I did this morning while eating my eggs:

1. Ran ‘e2fsck’ with no apparent problems.
2. Ran ‘ldconfig’ and received some, but not as many missing library errors.
3. Ran ‘updatedb’ with no apparent problems.
4. Tried ‘startx’ again and again got missing library errors.

The missing libraries are different between the first time and second time I tried ‘startx’. I’m not at home, so I can’t post the names of the missing libraries right now.

I am suspecting that this is a fairly common occurrence (unclean shutdowns for one reason or another). I’ve searched this forum and Googled, but can’t find any succinct solution or much more than what I’ve already tried. What I am looking for is a “procedure” for recovering the X server.

BTW. If this is a fairly common problem, it might be worthy of a sticky in one of the forums.
 
Old 03-13-2006, 10:48 PM   #2
jiml8
Senior Member
 
Registered: Sep 2003
Posts: 3,171

Rep: Reputation: 114Reputation: 114
It isn't all that common a problem. Can happen, but can happen with any OS. Basically your file system got damaged when the power went out; possibly your system got spiked when that happened.

If you are only missing X libraries, you might just reinstall X. That might be fastest. But it seems unlikely that only X got hosed. This might be a good time to use that backup that you have, in order to reload your system.

You do have a backup, right?
 
Old 03-14-2006, 10:05 AM   #3
weibullguy
ReliaFree Maintainer
 
Registered: Aug 2004
Location: Kalamazoo, Michigan
Distribution: Slackware-current, Cross Linux from Scratch, Gentoo
Posts: 2,705
Blog Entries: 1

Original Poster
Rep: Reputation: 220Reputation: 220Reputation: 220
I guess "common occurence" isn't really what I meant.

Something I've noticed reading the posts in this and other forums is people frustrated with Linux and wanting to go back to Windows. What I'm getting at is that 20 some odd years ago, if DOS had gotten hosed, alot of us may have gotten frustrated trying to fix it. The reason, in my opinion, that things like power failures aren't more than little hiccups in DOS/Windows is that we've fixed these things so many times they're second nature. And remember, we did it without an internet!

Now, trying to the same thing in Linux, noobs aren't familiar with the commands and options. Some of us don't mind searching the web and asking stupid questions in forums (those of us who have beaten our heads against the wall trying to fix something for the first time in DOS or Windows). I just hate to see someone give up on Linux over fairly simple problems.

What I haven't found is a website that provides some step-by-step instructions to deal with issues that can reasonably be expected to occur from time to time and other basic admin stuff.
 
Old 03-14-2006, 10:13 AM   #4
jiml8
Senior Member
 
Registered: Sep 2003
Posts: 3,171

Rep: Reputation: 114Reputation: 114
Huh.

I have had systems get so badly trashed in Windows when power failed that I couldn't get things to boot far enough to even let me try to make repairs. I have had to reinstall completely.

This once happened in my office. Power went down and the only system that was unaffected was the server that was on a UPS. Every other system was corrupted to the point that I had to wipe and reinstall.

When the power spikes, if a hard drive is writing at that time, then anything can happen, regardless of what OS you are using.

In the "old days" when a DOS system went down, it was no big deal because you were running from floppies anyway, and everyone backed up their floppies; the failure rates were so high that it never occurred to anyone to NOT do backups.

As far as finding a "one size fits all" website for Linux, you won't find one. The reason is that GNU/Linux systems are very complex, and will use a large number of different packages - and no two systems are the same. No one, no matter how long they have been using a *nix environment, knows all the commands and features. That is why sites like this are so useful.

For that matter, there is no "one size fits all" site for Windows either. Windows is arguably less complex than Linux because the environment is so very homogeneous, but it still is an enormously complex environment - and it is far more difficult to debug than *nix.

Certain basics always apply, though, and backing up is one of those basics. Any data that you have not backed up is data that you are willing to lose. This applies to Linux, and Windows, and DOS, and every other electronic data system out there.

Linux is very different architecturally and conceptually from Windows. It is much less opaque, which means that you can more easily see what is going on with it. This causes some people to get confused, but when you begin to grasp the differences - and mostly that consists of learning how to think in terms of Unix philosophy, rather than trying to force your Linux knowledge to fit your Windows philosophy, then you will find Linux to be generally much easier to debug than Windows.

Also, Linux is easier to back up because it has far fewer restrictions in how it handles files than Windows does. For instance (and importantly), you can't manipulate an open file in Windows; only the process that has the file open can manipulate it. Linux/Unix doesn't care. You can move the file, view it, rename it, add to it, or even replace it while it is open. Hence, you can backup while your system is running and without worrying about missing files because the OS won't let you copy them.

In fact - and I have done this - you can switch from one copy of Linux to another, then wipe out the partition that has your main Linux installation, rebuild that partition, and switch back to using that partition - all without rebooting.

What you really need to do is study the dd command and learn how to use it to back up your system partition(s). Here is how I do it - and this is specific to the exact architecture of the physical drive on which I have my system installed:

dd if=/dev/sdc of=/mnt/sdb1/sysimg.img bs=512 skip=4193028 count=19824147

I can run this command on the fly, and it backs up my system partition to an image file on another drive. I then gzip that image, burn it to DVD, and I have an image of the system. I can reinstall that image at any time.

But don't expect miracles. If there is a power transient, your system can get wrecked, whether it is Linux, or Windows, or anything else.

Last edited by jiml8; 03-14-2006 at 10:33 AM.
 
Old 03-14-2006, 11:49 AM   #5
jiml8
Senior Member
 
Registered: Sep 2003
Posts: 3,171

Rep: Reputation: 114Reputation: 114
And, actually, as I was writing the above post, I was actually running a backup of the system partition. When it finished, I gzipped it.

Now, as I write this post, I am using K3B to write the gzipped backup to a DVD.

Didn't have to stop what I was doing to do the backup, didn't have to worry about locked files, just copied the whole frickin' partition.
 
Old 03-14-2006, 12:04 PM   #6
rickh
Senior Member
 
Registered: May 2004
Location: Albuquerque, NM USA
Distribution: Debian-Lenny/Sid 32/64 Desktop: Generic AMD64-EVGA 680i Laptop: Generic Intel SIS-AC97
Posts: 4,250

Rep: Reputation: 60
You might also try doing a reinstall -upgrade. If only system files got hosed, your data might still be pretty much intact.

A related story: During the Y2K scare, my business got UPS's for every PC, preparing for power grid failures. (ha ha). But in spite of the fact that no such thing occured, it quickly became obvious that these things were worth their weight and cost. They're much lighter and cheaper nowdays.

Last edited by rickh; 03-14-2006 at 12:11 PM.
 
Old 03-14-2006, 12:44 PM   #7
sundialsvcs
Guru
 
Registered: Feb 2004
Location: SE Tennessee, USA
Distribution: Gentoo, LFS
Posts: 5,272

Rep: Reputation: 1086Reputation: 1086Reputation: 1086Reputation: 1086Reputation: 1086Reputation: 1086Reputation: 1086Reputation: 1086
Four things are a real life-saver...

(1) USB external hard-drives. They're based on laptop drives so they hold hundreds of megabytes, are relatively cheap (~$100 USD) and, if your port supports USB 2.0, are nearly as fast as built-in. (If the port doesn't, all devices automatically ratchets down to the 1.1 protocol.) There's also FireWire but that's a bit more pricey, albeit much faster yet. The drives neatly fit (hint hint) into a safe-deposit box, such as the one you can rent at that bank which is so close to that great little coffee shop (hint hint hint) that you pass by on the way to work.

(2) A backup-daemon that runs regularly. Even a cron job that runs rsync, putting the files somewhere else, preferably on a different drive altogether, is usually enough. Even better yet is a cron-job (and location) for each day of the week.

(3) Version-control systems, like CVS or SubVersion (svn). They are good for lots of things. Basically they are like "a file system with a history."

(4) When you have a nice clean copy of "Linux the way you want it," use rsync to make a backup copy of it and put it somewhere.
 
Old 03-14-2006, 02:41 PM   #8
weibullguy
ReliaFree Maintainer
 
Registered: Aug 2004
Location: Kalamazoo, Michigan
Distribution: Slackware-current, Cross Linux from Scratch, Gentoo
Posts: 2,705
Blog Entries: 1

Original Poster
Rep: Reputation: 220Reputation: 220Reputation: 220
Wow! Did I let the genie out of the bottle!

I agree with Jiml8, Linux doth not equal Windows. I wasn't being anti-Linux! In fact, I believe Linux to be superior technically to Windows as well as financially. Which is exactly why I'm making the move. I haven't found any software I use in Windows to lack an equivalent in Linux so I intend to make a clean break (at home anyway). You don't have to convince me.

I also agree that backing up your data is just good practice regardless of OS. I also agree that any OS can get totally hosed. But, I haven't had to reinstall Windows in years. Not because it doesn't go squirrely, just because I've learned to restore things to normal without such a brute force method. I gotta believe the same is possible with Linux.

There are certain admin/repair activities that are, conceptually anyway, the same in Windows and Linux. The differences (for basic use anyway) lies in the commands/options/syntax. For example, to check the status of and fix a disk in DOS I 'chkdsk' it. In Linux, at least in my feable understanding, I 'fsck' or 'e2fsck' it. Of course, from what I've seen, fsck is more powerful than chkdsk.

Most people making the change are Windows users. Until a Linux noob is able to think Linux, I believe it would be helpful to someone familiar with DOS/Windows to have some sort of "translater" to get over the hump. I think it's a shame to see someone give up because of a minor snag.

rickh, I'll give that a try. I can use the terminal, so I "know" the data is still there. There's really nothing important on the machine right now because I expect to break it while I'm getting up to speed with Linux.

sundialsvcs, (1) is sound advice regardless of the OS you use. However, I prefer the brewpub on my home from work (or to work, I guess, would be OK too). (2) is again my point, I can schedule backups in Windows. Conceptually the same, commands different. (3), well Windows sorta can...

BTW Jiml8, touche on the DOS floppies...it's been awhile.
 
Old 03-14-2006, 09:33 PM   #9
jiml8
Senior Member
 
Registered: Sep 2003
Posts: 3,171

Rep: Reputation: 114Reputation: 114
Quote:
Originally Posted by Arow
Most people making the change are Windows users. Until a Linux noob is able to think Linux, I believe it would be helpful to someone familiar with DOS/Windows to have some sort of "translater" to get over the hump. I think it's a shame to see someone give up because of a minor snag.
Fundamentally, I agree with this. The reality is that such a translator is difficult because the conceptual/architectural differences between the systems make it so.

That said, a lot of this is already done, to the extent possible. There are gui tools in Linux that do system management/maintenance in a fashion that is at least analogous to what is done in Windows.

But, beyond the very basics, the differences between Windows and *nix overwhelm the similarities.

Essentially, *nix is a multi-user command line oriented operating system that can have a graphical shell superimposed on it. Modern Windows is strictly graphical and essentially single-user (multiple users CAN use it, with very serious limitations), with a very limited command line capability provided.

IMNSHO, the Windows registry is the worst computing innovation in the last 20 years, and there is no *nix equivalent; similar functionality is found in the /etc directory and in the various hidden files kept in individual users' home directories.

Also, the way Windows handles drives is peculiarly crude and primitive. I actually do not understand why Microsoft hasn't fixed that; it could be done in a fashion that is transparent to the user and to existing applications, while adding the flexibility that Windows desperately needs.

*nix does this right; all drive references are via mountpoints and symlinks, and these references can be changed on the fly. Compare this to the drive letter mechanism of Windows (which actually refers to a piece of hardware). This is where Windows users go wrong; they totally lack the concept of links because (other than those primitive "shortcuts") Windows simply does not have or employ the concept.

To consider the implications, consider what is involved to move a package in Windows. Very difficult; generally you have to reinstall it. In *nix, you move the directory containing the package and update one link that points to it. Done.

Now, it is explicitly true that Microsoft intentionally tries to hide things from you. They do this so that they don't overwhelm their unsophisticated users, but by doing so they make it very difficult for their sophisticated users to work on the system. Compare that to *nix, with all the logging and the transparency of operation.

In Windows, you often can't figure out what the hell it is doing, because it refuses to tell you. In *nix, you can always figure out what the hell it is doing, because it tells you. You may not understand what it is telling you, but the fact that it tells you lets you chase off in the right direction to find the solution.

The upshot is that you can't really translate well between the two systems. They are very different, and they require different ways of thinking. GNU/Linux has generally been suffering from immaturity in its GUI relative to Windows, but even that is now pretty much history. New users can quickly be doing the most basic things (word processing, web browsing) in Linux just as they would in Windows and beyond that they pretty much have to learn the philosophy of *nix to be effective.
 
Old 03-15-2006, 07:57 AM   #10
weibullguy
ReliaFree Maintainer
 
Registered: Aug 2004
Location: Kalamazoo, Michigan
Distribution: Slackware-current, Cross Linux from Scratch, Gentoo
Posts: 2,705
Blog Entries: 1

Original Poster
Rep: Reputation: 220Reputation: 220Reputation: 220
I absolutely agree. Microsoft has a business model that works. It essentially made the PC available to every household in the world (and made someone the richest man in the world). Unfortunately, as you pointed out, to achieve that they had to hide things from the user. Although, I'm sure greed and ego played a part in the genesis of modern Windows as well.

Linux, and other open source OS, provide a solution for the more technically saavy user. It's just frustrating when you're pretty sure of what the problem is and know there's got to be a few quick commands you can throw at the machine, but you don't know what they are (yet). I guess it's natural to think, "If this was DOS/Windows, I'd do..." Maybe it doesn't matter, because most people using Windows today have probably never used anything but a GUI.

It's also frustrating (for me anyway) to see people willing to try something other than Windows and then give up because they run into what is probably a minor problem. It's frustrating because ultimately it gives Microsoft no incentive to compete. That lack of competition is why they don't change things like the registry and the way they handle drives. I speak, of course, as an engineer who would welcome any stimuli to innovation.

I think the GUI available for Linux will go a long way towards the growth of Linux for non-server, non-techy users. My kids could care less whether they're playing games on Windows or Linux. But, the GUI makes the OS opaque to these users as well. In many ways, no different than Windows. The difference lies in the fact that innovation is the name of the game with these open source OS. It's vitally, critically important that we create new tech-saavy users of these OS to ensure that the Windows syndrome doesn't set in. Hence, my frustration with people giving up too soon.

Anyway, we've clearly digressed in this thread from my original problem. I got things back to normal on my machine. I probably used a more Neanderthal way than I needed, but I didn't have to reinstall everything. Since I could boot to the terminal and e2fsck said everything was hunky-dory, I just reinstalled Xorg using yum. Rebooted and life was good. This seemed like the quickest solution.
 
Old 03-15-2006, 02:43 PM   #11
jiml8
Senior Member
 
Registered: Sep 2003
Posts: 3,171

Rep: Reputation: 114Reputation: 114
Quote:
Since I could boot to the terminal and e2fsck said everything was hunky-dory, I just reinstalled Xorg using yum. Rebooted and life was good. This seemed like the quickest solution.
Which is what I suggested you try in my first post...
 
Old 06-30-2006, 10:58 AM   #12
PingFloyd
Member
 
Registered: Jun 2006
Posts: 94

Rep: Reputation: 16
Quote:
Originally Posted by jiml8

IMNSHO, the Windows registry is the worst computing innovation in the last 20 years, and there is no *nix equivalent; similar functionality is found in the /etc directory and in the various hidden files kept in individual users' home directories.
Thank god.

I got to agree with you about the registry being one of the worst computing innovations. I've felt that way since the it's introduction. It's one of those microsoft created paradigms that is forced upon it's user base. The funny thing is that I recall alot of the text in the Windows 95 Resource Kit always trying to evangalize this paradigm (along with many other ones). Seems a good portion of it's pages are filled with text that is self back patting about the "new innovation of the registry" (as well as other new paradigms that they were "pioneering" that turning point in their OSes) and how it's a superior implementation vs. things such as ini and config files etc.

I find it hard to believe that it's better to put all of one's eggs in one flimsy and vulnerable basket and then take things a step further by allowing practically everyone and everything to be able to make modifications to it in what ever manner they/it see fit all the while have non-existent means by which to track and undo such changes by default. Oh wait, you can buy a handy dandy bloatware package that adds on such functionality (as well as, a tons of other functions that are of no use and half baked all for the purpose of giving the illusion of a justification of an overinflated price tag)! Gotta love being nickel and dimed for functionality that is fundimentaly needed as a result of a flawed "innovation" that is being pushed on one.

Anyone remember the old story of "The Emperor's New Clothes"? Microsoft has always reminded me of the tailors in that tale.

Anyway, sorry for the tangent. I just couldn't resist inserting my two cents when the windows registry was brought up. It was always one of those things that I was pretty good at modifying but was always left with asking myself "why?". The more one gets into the inards of windows the more that question comes up. That is with how limited you are from being able to get into it's inards, and that's pretty shallow since it's such a closed system. Windows is pretty much the epitome of the opposite of open source. Sometimes I wonder how far open source would have come if there wasn't a Microsoft to act as a driving force and an example of what to be the opposite of.

You might wander what I mean by driving force. What I mean by that is that perhaps microsoft creating a platform, that is very hard to be content with for certain users, has given some of them motivation to be a part of the development of a platform that shows how things could be done so much better.

Also, don't get me wrong. I'm not one of these "Bill Gates is the Devil" types (maybe he's the anti-christ though j/k). Afterall, there is something nice about the concept of a system that the average user can be able to work. If Windows or something like it didn't exist then people like my girlfriend, father, sister, and mother would be left out in the cold since they don't have the patience, time, nor aptitude to be able to try to tackle a system such as Linux (That's not to sound elitist nor as a knock against them, but more to point out that not every is the same in the ability to learn different types of concepts. In this particular case, computing). Windows gives them an operating system that is simpler and more accessible for them which I feel is a virtue for this reason. It's great that there are platforms available that keep things simple enough that they can take an interest in computing. Linux would be way to overwhelming for them unfortunately. I'm sure if they had enough time and patience they probably could become with Linux, but that is something that is going to take alot of time and support from me. Which is just fine with me, but it's better that I sink and swim in the environment first since I'm much more determined and it take a great deal more for me to be discouraged when it comes to things like computing.

Really I think the most important thing is for more people to understand that there is an alternative to Windows and what the real ramifications of it is. Alot of people are very pro Windows don't seem to really understand the paradigms of Linux and Open Source. For instance, one person once said to me, "What do you think about Linux? I don't think they can compete with Microsoft. I'm sure they'll be bought up by them just like everything else". This pretty much shows that they really don't understand the concept of open source. It can be a very hard concept to grasp for most people. This especially seems true of older generations that have a very molded sense of "reality". And don't anyone get offended by that last statement. That was not meant to sound as a generalization (then again I'm probably what could be an old fogey these days), it was more to say that most people that I know, this tends to be the norm for them.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Fedora Core 2 logout causes unclean shutdown Ethan Linux - General 0 10-12-2004 01:57 PM
umount /var device is busy (unclean shutdown) feetyouwell Linux - Software 3 09-13-2004 06:18 PM
hostname resetting to localhost on unclean reboot brian_h1 Linux - Networking 0 05-11-2004 08:18 PM
httpd: Unclean shutdown of previous Apache run mfitzpat Linux - Software 1 04-14-2004 02:08 PM
Help! Reboot, System Unclean Error. wwnn1 Linux - General 1 05-17-2002 11:00 AM


All times are GMT -5. The time now is 08:52 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration