Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Upgrading UDEV, /dev/sda and /dev/md0 disappeared
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
RayDude
Advocate
Advocate


Joined: 29 May 2004
Posts: 2050
Location: San Jose, CA

PostPosted: Thu Oct 11, 2012 4:06 pm    Post subject: Upgrading UDEV, /dev/sda and /dev/md0 disappeared Reply with quote

I'm remote upgrading a system I set up for a friend a number of years ago. During the latest emerge -DNuv world, udev was upgraded and I lost /dev/sda and /dev/md0.

Since there are kernel modifications required for the new udev and consolekit, I need to install the new kernel, but alas the kernel can't mount the device because it is gone.

Luckily, the root partition is still accessible and emerge is ongoing.

Is there a way I can get /dev/sda back without rebooting. I don't want to risk a reboot until I'm certain it will actually reboot.

Thanks in advance,

Raydude
_________________
Some day there will only be free software.


Last edited by RayDude on Fri Oct 12, 2012 2:25 pm; edited 2 times in total
Back to top
View user's profile Send private message
eccerr0r
Watchman
Watchman


Joined: 01 Jul 2004
Posts: 9601
Location: almost Mile High in the USA

PostPosted: Thu Oct 11, 2012 5:11 pm    Post subject: Reply with quote

You can

mknod /dev/sda b 8 0
mknod /dev/sda1 b 8 1
mknod /dev/sda2 b 8 2
... etc., manually. Look for the major/minor numbers from a working machine.

/dev/md0 is major 9, minor 0 if you didn't do anything special. Again from a working machine with same config would be helpful.
_________________
Intel Core i7 2700K/Radeon R7 250/24GB DDR3/256GB SSD
What am I supposed watching?
Back to top
View user's profile Send private message
RayDude
Advocate
Advocate


Joined: 29 May 2004
Posts: 2050
Location: San Jose, CA

PostPosted: Thu Oct 11, 2012 6:16 pm    Post subject: Reply with quote

Awesome! Thanks dude. That totally worked.
_________________
Some day there will only be free software.
Back to top
View user's profile Send private message
eccerr0r
Watchman
Watchman


Joined: 01 Jul 2004
Posts: 9601
Location: almost Mile High in the USA

PostPosted: Thu Oct 11, 2012 8:44 pm    Post subject: Reply with quote

N/P. That's probably the biggest hate I have with PC's, remote upgrades accidentally causing no-boot situations...
I am remotely updating a Gentoo box too, it's my dad's. I always am very worried the next emerge will cause a no-boot situation...
Especially because the machine is 1500 miles away...
_________________
Intel Core i7 2700K/Radeon R7 250/24GB DDR3/256GB SSD
What am I supposed watching?
Back to top
View user's profile Send private message
steveL
Watchman
Watchman


Joined: 13 Sep 2006
Posts: 5153
Location: The Peanut Gallery

PostPosted: Fri Oct 12, 2012 10:27 am    Post subject: Reply with quote

eccerr0r wrote:
N/P. That's probably the biggest hate I have with PC's, remote upgrades accidentally causing no-boot situations...
I am remotely updating a Gentoo box too, it's my dad's. I always am very worried the next emerge will cause a no-boot situation...
Especially because the machine is 1500 miles away...

The only way I know that you can mitigate that, is to have some advance warning of upcoming upgrades, eg that require some extra tweaking after install, and provide a mechanism to do the tweaking for you, at a time of your choice, so you can monitor it if anything goes wrong, and hold the upgrade off otherwise. The canonical example would be the expat upgrade a few years ago, which motivated /etc/warning in update.

To make that work, though, takes collaboration from people who test specific unstable packages or run unstable across the board, and see the breakage coming, in time to put an entry in the file. (news-items are generally easy enough.) I'm not as in-touch with it all as I used to be; I only see it from the stable-user tree side.

I realise it's not ideal, since it's a porcelain wrapper around emerge; but it works (there's been a few rough upgrades it's taken me through in a nice automated manner. When I get a heads-up, I'll typically try the procedure out here, and add any code needed: it's useful for the robustness of the application.) There was a post from ferringb/Brian Harring on the dev ml a few months ago about this sort of problem, saying we needed some sort of mechanism. I wasn't around at the time, or I'd have responded, since update has been doing this for about 4 years.

I've been meaning to put in a CHANGED entry for a while, so that for example whenever xorg-server is upgraded, the drivers automatically get updated as well (there have been specific entries around specific upgrades before, but it's an ongoing issue.) If you do look at it, make sure you check the git version as I haven't done a release for months (everyone I know just uses the git ebuild.) Guess I should do a release soon, as it's working solidly, before I break anything else.
Back to top
View user's profile Send private message
RayDude
Advocate
Advocate


Joined: 29 May 2004
Posts: 2050
Location: San Jose, CA

PostPosted: Fri Oct 12, 2012 2:25 pm    Post subject: Reply with quote

Update:

Well, it rebooted and the /dev/sd and /dev/md and audio devices did not populate...

I found a thread that said upgrading the kernel fixed the problem for someone else so I upgraded the kernel and it rebooted and audio still didn't work (an /dev/sd and /dev/md were not present).

So I updated to the latest udev, openrc, etc.

Now he has no networking device and I can't log in remotely.

I'm positive I installed the modules. So it must be udev misbehaving.

Anything a computer novice can do to get his network running?

I had him try to bring up eth0 and eth1 with ifconfig but it said, "device not found."

Argh.

He's going to have to send it to me through a mutual friend.

Help?
_________________
Some day there will only be free software.
Back to top
View user's profile Send private message
eccerr0r
Watchman
Watchman


Joined: 01 Jul 2004
Posts: 9601
Location: almost Mile High in the USA

PostPosted: Fri Oct 12, 2012 2:31 pm    Post subject: Reply with quote

I do have some forewarning of issues... how, one may ask?

It's not perfect, but I do have machines that have similar configuration as the target machine, and I have to update those as well... if I see problems on the "canary" then I'm sure to see them on the "real thing".

Unfortunately this is not always 'efficient' but it helps. Luckily I need to update my own boxes anyway.

(Target machine is a core2quad with Intel G31 chipset, desktop. I have other Intel graphics machines that if fail, likely will fail on that machine too!)

(and yes, I got bitten hard by expat, and others, they've been forgotten though... I'm more worried about updates that affect network connectivity: These packages I'm most worried about:
- Openssh and its dependencies (openrc specifically, but also openssl, etc.)
- Networkmanager and its dependencies (dbus, polkit, consolekit, nm-applet, gnome, X11, etc. OUCH)
- Kernel. I hope I don't need to upate this frequently. One mistake on network driver or its dependencies (like pci, ipv4, etc. as well as its userland stuff (udev)) will cause a no-boot situation
- Grub. But I don't need to update this often until Gentoo switches over to Grub2)

As for the original poster, yes, looks kind of dead :( Apparently kernel/udev has problems. I always make sure I grab the old .config as a starting point, never start building a fresh kernel for an existing machine... And the canary is mandatory... And if I really F**K up, I send him a new machine :(
_________________
Intel Core i7 2700K/Radeon R7 250/24GB DDR3/256GB SSD
What am I supposed watching?
Back to top
View user's profile Send private message
RayDude
Advocate
Advocate


Joined: 29 May 2004
Posts: 2050
Location: San Jose, CA

PostPosted: Fri Dec 07, 2012 9:17 am    Post subject: Reply with quote

FYI: he sent the system down to me and I installed Kubuntu. Much easier to remotely manage.
_________________
Some day there will only be free software.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum