SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
And if any process (backgrounded shell, subshell, whatever) is in that directory, it's going to be 'busy'. Make sure that you cd all your shells/file managers/whatnot out of the mount point.
Do 'ps ux' if you still get it, because you probably missed a shell.
Might try making your alias point to '/mnt/cdrom' or whatever's in fstab, too, instead of the device directly.
Three questions...
(1)
How do we make the alias permanent.
It is gone after I logout.
None of the books I have give you a way to do this.
(2)
Do you mean to unmount the location I mounted my cdrom to?
I mounted it to /root/Desktop/cdrom.
So should I umount /root/Desktop/cdrom?
Quote:
Might try making your alias point to '/mnt/cdrom' or whatever's in fstab, too, instead of the device directly.
(3)
[edit1]
I just found the ps command in my book. Process reporting.
That is a good command to know. Thanks. Scratch the following question.
[/edit]
What is this?
Quote:
'ps ux'
Last edited by xviddivxoggmp3; 03-10-2004 at 05:27 PM.
~
1014>> alias | grep cdrom
alias mcdr='mount -v /mnt/cdrom'
alias ucdr='umount -v /mnt/cdrom'
~
1015>> cat /etc/fstab | grep cdrom
/dev/cdrom /mnt/cdrom iso9660 noauto,user,ro 0 0
~
1016>> ls -l /dev/cdrom
lrwxrwxrwx 1 root root 8 Nov 26 12:17 /dev/cdrom -> /dev/sr1
~
1017>> ls -l /dev/sr1
brw-r----- 1 root disk 11, 1 Apr 13 1999 /dev/sr1
My alias means to substitute 'ucdr' with 'umount -v /mnt/cdrom' which references /etc/fstab, which tells umount '/mnt/cdrom' means 'unmount dev/cdrom from that mountpoint' and '/dev/cdrom' is actually a link to '/dev/sr1'. (I have scsi emulation, hence the funky device.)
Anyway - then I just issue 'mcdr' and 'ucdr'. But 'mount' should show whether it's mounted or not and 'ps' should show if any processes are running that might be 'in' it. You have to have a mounted device and be clear of the mountpoint in order to unmount it. If that's the case, then I dunno why it's saying it's busy and refusing to unmount. Could try 'lsof', too, to see if there's any open files. That could hang it up, too.
Re:#1: my .bashrc is just a symlink and I stick everything in ~/.bash_profile so I don't have to worry with it but that's not SOP for reasons I have yet to figure out.
ok i finally got the .bashrc to save aliases for reboot and login.
How do you reload the .bashrc into your box w/o rebooting?
I'm getting tired of recogniziing an error in my script and then having to wait for the reboot to test the new script.
and how do you make alias commands accesable to non-su user?
ever time i try to execute cdr from a non-su user it says request can only be made by root.
Last edited by xviddivxoggmp3; 03-11-2004 at 11:55 PM.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.