You are not logged in.

#1 2012-02-19 14:25:21

Lennie
Member
From: Sweden
Registered: 2011-10-12
Posts: 146

[Solved] Arch crashed after hard shutdown. What can I learn from this?

... besides that I should be more careful with regular backups... My last backup was 12 days old, so I had some work to make it almost as it was before. I restored it to another partition, so I still have my crasched Arch to save files from, but I don't think it's possible to recover it.

So what happened was, Arch hang at shutdown yesterday, so I had to press the button. Today when I booted it up, I came to the console which said:

Arch contains a file system with errors, check forced
Special (device/socket/fifo) inode 1329330 has non-zero size. FIXED
Arch: Inode 1329331, i_blocks is 32, should be 0. FIXED
[...](8 similar lines)
Entry 'bvnc' in /usr/bin (1308840) has an incorrect filetype (was 7, should be 3).

Arch: UNEXPECTED INCONSISTENCY: RUN fsck MANUALLY.
    (i.e, without -a or -p options)

So I ran 'fsck' and it said something was wrong with files in /usr/bin, one at a time and asked if I wanted to fix it. I answered yes to a few of them, then I cancelled.

I booted up another installed system, and chrooted into Arch and ran 'pacman -Syu' but I got errors. I think the problem was that it couldn't mount /usr/bin. If I try to open it in Thunar I get this error: "Error stating file '/media/Experiment/usr/bin/avahi-set-host-name': Input/output error." I remember that file was one of those fsck 'fixed'...

I guess I crasched it completely by running fsck? So my question now is, what could I have done instead? If this happen again... The message on screen told me to run fsck, was it wrong to do as it said? Or was it already crashed by that hard shutdown? I know Windows is sensitive to that, but I didn't think Linux is. I have shutdown by power button many times with different distros, and nothing has ever happened before. It was long time ago since I had to do so in Arch, several months I think.

I run pacman -Syu every day, so I don't know if it was those updates I installed yesterday that made it hang at shutdown.
From pacman.log

[2012-02-18 16:15] Running 'pacman -Syu'
[2012-02-18 16:15] synchronizing package lists
[2012-02-18 16:15] starting full system upgrade
[2012-02-18 16:16] upgraded gmrun (0.9.2-3 -> 0.9.2-4)
[2012-02-18 16:16] upgraded libcaca (0.99.beta17-1 -> 0.99.beta17-2)
[2012-02-18 16:16] upgraded libdv (1.0.0-3 -> 1.0.0-4)
[2012-02-18 16:16] upgraded libidl2 (0.8.14-1 -> 0.8.14-2)
[2012-02-18 16:16] upgraded libsidplay (1.36.59-4 -> 1.36.59-5)
[2012-02-18 16:16] upgraded libvisual (0.4.0-3 -> 0.4.0-4)
[2012-02-18 16:16] upgraded obconf (2.0.3.git20100309-2 -> 2.0.3.git20100309-3)
[2012-02-18 16:16] upgraded opencore-amr (0.1.2-1 -> 0.1.2-2)
[2012-02-18 16:16] upgraded openslp (1.2.1-3 -> 1.2.1-4)
[2012-02-18 16:16] upgraded unzip (6.0-5 -> 6.0-6)

Last edited by Lennie (2012-02-20 07:59:49)

Offline

#2 2012-02-19 16:33:11

DSpider
Member
From: Romania
Registered: 2009-08-23
Posts: 2,273

Re: [Solved] Arch crashed after hard shutdown. What can I learn from this?

How, exactly, do you normally shut it down? Post the exact command/method that you use.

And what filesystem type do you use for the root partition? Because ext4 is a journalling filesystem and hard resets (like a sudden power failure) should not faze it.


"How to Succeed with Linux"

I have made a personal commitment not to reply in topics that start with a lowercase letter. Proper grammar and punctuation is a sign of respect, and if you do not show any, you will NOT receive any help (at least not from me).

Offline

#3 2012-02-19 16:52:21

Lennie
Member
From: Sweden
Registered: 2011-10-12
Posts: 146

Re: [Solved] Arch crashed after hard shutdown. What can I learn from this?

I have:
Ext4
Openbox and oblogout
Shutdown command:

shutdown = dbus-send --system --print-reply --dest="org.freedesktop.ConsoleKit" /org/freedesktop/ConsoleKit/Manager org.freedesktop.ConsoleKit.Manager.Stop

I use Slim to login, and everytime I shutdown I see like a textlogin 1-2 seconds before it shuts down. But yesterday it hang there. It looked like a prompt but I couldn't write anything, no response. I waited a few minutes before I pressed the power button.

Offline

#4 2012-02-19 17:34:18

DSpider
Member
From: Romania
Registered: 2009-08-23
Posts: 2,273

Re: [Solved] Arch crashed after hard shutdown. What can I learn from this?

Wow. That is one long-ass command. I'm sitting on ext4 and using Openbox for over 2 years now. This is how I shut down (from a "System" submenu created using obmenu), and I've never had a problem like yours:

# sudo poweroff

This is basically my sudoers file:

# sudo EDITOR=nano visudo
root    ALL=(ALL) ALL
yourusername ALL=(ALL) ALL

yourusername ALL=NOPASSWD: /bin/mount, /bin/umount
yourusername your_hostname=NOPASSWD: /sbin/reboot, /sbin/poweroff

PS: SLiM is no longer developed (wiki).

Last edited by DSpider (2012-02-20 15:00:02)


"How to Succeed with Linux"

I have made a personal commitment not to reply in topics that start with a lowercase letter. Proper grammar and punctuation is a sign of respect, and if you do not show any, you will NOT receive any help (at least not from me).

Offline

#5 2012-02-19 18:28:40

darkbeanies
Member
Registered: 2009-01-14
Posts: 142

Re: [Solved] Arch crashed after hard shutdown. What can I learn from this?

DSpider wrote:

Wow. That is one long-ass command.

Yeah, why not

dbus-send shutdown

Instead? 

I use the dbus method to shutdown too.  Never caused me any problems like Lennie's though.

Last edited by darkbeanies (2012-02-19 18:29:01)

Offline

#6 2012-02-19 18:49:36

Lennie
Member
From: Sweden
Registered: 2011-10-12
Posts: 146

Re: [Solved] Arch crashed after hard shutdown. What can I learn from this?

That command was already in oblogout when I installed it, so I didn't write it myself... It has worked just fine for more than 4 months, so I don't think that caused the crasch.

Maybe time to change Slim for another DM now, I didn't know it was outdated.

Offline

#7 2012-02-19 18:59:48

b4data
Member
Registered: 2010-12-14
Posts: 141

Re: [Solved] Arch crashed after hard shutdown. What can I learn from this?

DSpider wrote:

Wow. That is one long-ass command

That's the default given with obshutdown. I usually change it via ~/.obshutdown.rc to

logout =         openbox --exit
shutdown =       sudo shutdown -h now
restart =        sudo shutdown -r now
lock = 
switch = 
suspend =        dbus-send --system --print-reply --dest="org.freedesktop.UPower" /org/freedesktop/UPower org.freedesktop.UPower.Suspend
hibernate =      dbus-send --system --print-reply --dest="org.freedesktop.UPower" /org/freedesktop/UPower org.freedesktop.UPower.Hibernate
custom =

(I don't use suspend/hibernate so I've included them for reference, don't know whether they work or not hmm)

This is all by the by though, anyone have any thoughts on helping Lennie with his actual problem?

Lennie wrote:

So what happened was, Arch hang at shutdown yesterday, so I had to press the button. Today when I booted it up, I came to the console which said:

Arch contains a file system with errors, check forced
Special (device/socket/fifo) inode 1329330 has non-zero size. FIXED
Arch: Inode 1329331, i_blocks is 32, should be 0. FIXED
[...](8 similar lines)
Entry 'bvnc' in /usr/bin (1308840) has an incorrect filetype (was 7, should be 3).

Arch: UNEXPECTED INCONSISTENCY: RUN fsck MANUALLY.
    (i.e, without -a or -p options)

So I ran 'fsck' and it said something was wrong with files in /usr/bin, one at a time and asked if I wanted to fix it. I answered yes to a few of them, then I cancelled.

I booted up another installed system, and chrooted into Arch and ran 'pacman -Syu' but I got errors. I think the problem was that it couldn't mount /usr/bin. If I try to open it in Thunar I get this error: "Error stating file '/media/Experiment/usr/bin/avahi-set-host-name': Input/output error." I remember that file was one of those fsck 'fixed'...

I guess I crasched it completely by running fsck? So my question now is, what could I have done instead?

Edit:

Lennie wrote:

Maybe time to change Slim for another DM now

You might like to take a look at this link:
https://wiki.archlinux.org/index.php/St … sh_profile
and protect yourself from the vagrancies of display managers smile

Last edited by b4data (2012-02-19 19:20:05)

Offline

#8 2012-02-20 07:58:48

Lennie
Member
From: Sweden
Registered: 2011-10-12
Posts: 146

Re: [Solved] Arch crashed after hard shutdown. What can I learn from this?

I mark this thread as solved. I guess that what one can learn from this is that there are no guarantees, even with ext4 it can crasch after a hard reset. From now on I will be more careful with my backups. (I didn't loose anything important, but it gave me more work because my backup was so old.)

Offline

Board footer

Powered by FluxBB