LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 11-23-2003, 10:56 AM   #1
yapp
Member
 
Registered: Apr 2003
Location: Netherlands
Distribution: SuSE (before: Gentoo, Slackware)
Posts: 613

Rep: Reputation: 30
[gentoo] umount /usr - device busy


Hi.

I', currently installing my gentoo system, and I want to resize the /usr partition. It's formatted as reiserfs.

After returning to single user mode, I wasn't able to "umount /usr". It says, device busy, but this is the output from fuser -v:
Code:
                     USER        PID ACCESS COMMAND
/usr/                root     kernel mount  /usr
does anyone know how I can unmount the usr partition? I didn't put those files on another partition because it looked like fun.
 
Old 11-23-2003, 02:05 PM   #2
chup
Member
 
Registered: Aug 2003
Location: South Africa
Distribution: Ubuntu (Feisty)
Posts: 280

Rep: Reputation: 31
this may sound dumb, but you arent in the /usr directory when you are trying to unmount it?
also, have you tried rebooting and then resizing the partition?
 
Old 11-23-2003, 02:22 PM   #3
teval
Member
 
Registered: Jul 2003
Location: Toronto, Canada
Distribution: Gentoo
Posts: 720

Rep: Reputation: 30
No... you can't just not be in it, a lot of programs run from there.
It used to be that *nix didn't need usr to function, and usr was mostly glitter, but now a lot of the core programs are in usr
If you really want to try it's like this..

fuser -k -m /usr

You should definitely not be in X when doing this.. and make sure any program you want is compiled without dependancies to libc, and.. that you have all the library files you need.
 
Old 11-23-2003, 03:14 PM   #4
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
you have of course still got your gentoo live cd.... you can always just boot to that...
 
Old 11-24-2003, 05:13 AM   #5
8nasmith
Member
 
Registered: Oct 2003
Location: Cornwall, UK
Distribution: Fedora Core 4
Posts: 268

Rep: Reputation: 30
i have purchaced gentoo 1.2 not very experianced so how is it at installing
 
Old 11-24-2003, 05:17 AM   #6
Crashed_Again
Senior Member
 
Registered: Dec 2002
Location: Atlantic City, NJ
Distribution: Ubuntu & Arch
Posts: 3,503

Rep: Reputation: 57
Its like going to the dentist but afterwards instead of getting a lollipop you get an ice cream sundae!
 
Old 11-24-2003, 05:22 AM   #7
8nasmith
Member
 
Registered: Oct 2003
Location: Cornwall, UK
Distribution: Fedora Core 4
Posts: 268

Rep: Reputation: 30
ha ha ha wow i never got it to work rthough i am not very good with the commands
 
Old 11-24-2003, 05:23 AM   #8
8nasmith
Member
 
Registered: Oct 2003
Location: Cornwall, UK
Distribution: Fedora Core 4
Posts: 268

Rep: Reputation: 30
www.gento.org i think!! doent really help me
 
Old 11-24-2003, 05:57 AM   #9
yapp
Member
 
Registered: Apr 2003
Location: Netherlands
Distribution: SuSE (before: Gentoo, Slackware)
Posts: 613

Original Poster
Rep: Reputation: 30
Thank you for all the replies. I'm a little amazed. thanks.

Quote:
this may sound dumb, but you arent in the /usr directory when you are trying to unmount it?
also, have you tried rebooting and then resizing the partition?
I've returned to single-user mode. (telinit 1), and logged in again; my working directory is /root/. No programs are running except the agetty processes, /bin/bash, and the kernel threads.

Quote:
It used to be that *nix didn't need usr to function, and usr was mostly glitter, but now a lot of the core programs are in usr
What kind of programs? I thought a linux system is supposed to work without /usr, because all essential tools are in /bin, /sbin, and /lib


Quote:
you have of course still got your gentoo live cd.... you can always just boot to that...
I have knoppix on cd, and slackware is still the default OS. However, I don't like the idea of rebooting to resize an non-root partition. If I remove slackware, I want this thing to work as well. .. without using knoppix, or having to download that live CD, because my system was installed from a stage 1 tarbal.




@8nasmith:
you could install gentoo from mandrake (while your system is running). emerging all packages from the chroot. If gentoo is completely working (and enabled in your boot manager), you could choose to make gentoo your default OS. I've found the installation howto very helpfull, and the rest of the howto's too. The screen command is very useful to keep your machine compiling while you logoff.. but I have to agree.., you need to work in the console a lot, but it's a great way to learn it

Last edited by yapp; 11-24-2003 at 06:46 AM.
 
Old 11-24-2003, 03:53 PM   #10
teval
Member
 
Registered: Jul 2003
Location: Toronto, Canada
Distribution: Gentoo
Posts: 720

Rep: Reputation: 30
Yes.. supposed to
use strace to find out if the programs you need depend on libs from /usr

info strace
Or.. ltrace, not sure which is better for this case :P
 
Old 12-01-2003, 03:50 AM   #11
yapp
Member
 
Registered: Apr 2003
Location: Netherlands
Distribution: SuSE (before: Gentoo, Slackware)
Posts: 613

Original Poster
Rep: Reputation: 30
I've been able to solve my problem

"fuser -v -m" showed that /bin/login was using the /usr partition. The /bin/login program keeps running after a login, something that I didn't see with slackware before (as far as I can remember)

However, the most odd problem: If I reboot the machine without /usr being mounted, /bin/login still works. I can login to a shell, the profile gets some problems because /usr/bin/whoami can't be found, etc.. but it's working. I can even mount and unmount /usr/

After some experiments I've discovered that it was possible to kill the running login process. a new agetty will be spawned, but it shares the terminal with the shell (which is also running at that time), this makes it impossible to type new input.

But something like this seams to work:
Code:
killall login; sleep 0.2; umount /usr; exit
you'll get a new agetty login, and the shell will unmount /usr before it exits. After entering your username, the new /bin/login won't use /usr.. and you can start resizing the /usr partition with resize_reiserfs.

perhaps I should submit this problem to the gentoo developers I find this problem very weird, and I can't believe this is intentional :P

Last edited by yapp; 12-01-2003 at 03:52 AM.
 
Old 12-02-2003, 11:03 AM   #12
8nasmith
Member
 
Registered: Oct 2003
Location: Cornwall, UK
Distribution: Fedora Core 4
Posts: 268

Rep: Reputation: 30
thanks that a brill site gentoo is great got it working and running thanks loads
 
  


Reply



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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
umount :device busy Pedroski Linux - Hardware 14 12-29-2004 03:37 PM
umount - device is busy - with what??? Moebius Linux - Software 16 12-08-2004 10:32 AM
fam and umount says device is busy Brian1 Fedora 2 10-05-2004 07:33 PM
umount /var device busy winchester169 Linux - Networking 1 06-25-2004 07:53 PM
umount: /mnt/a5: device is busy PTBmilo Linux - General 2 01-31-2003 10:48 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 04:18 AM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration