LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 07-22-2007, 06:42 AM   #1
kailun
Member
 
Registered: Oct 2003
Distribution: Slackware
Posts: 48

Rep: Reputation: 15
HAL and the console


I've got automounting working (at least for my cdrom / dvd / optical drive) in KDE.

However, I'm not always in X (my runlevel defaults to console) so I was wondering if the automounting features work outside of KDE? I did try, but nothing happens. What does KDE do to initiate the automount?

As it stands, I can still mount the CD / DVD if I drop into root and issue:

mount -t auto /dev/cdrom /mnt/cdrom

then drop out as my normal user. (I use the '-t auto' because there's no longer an /etc/fstab entry for my optical drive)

Is there a better way of handling it than this (in the console)?

Thanks
 
Old 07-22-2007, 07:04 AM   #2
MS3FGX
LQ Guru
 
Registered: Jan 2004
Location: NJ, USA
Distribution: Slackware, Debian
Posts: 5,852

Rep: Reputation: 361Reputation: 361Reputation: 361Reputation: 361
HAL does not actually mount anything, or even do anything with connected devices, that is a popular misconception. What HAL actually does is inform the system that a device has been connected to the system, it is up to some software application on the system to be listening for that announcement and act accordingly (in this case, mount the file system on the device). KDE is handling that for you, so once you are outside of X, it no longer happens. HAL is still doing it's thing, but nobody is listening anymore.

To rectify this you need to use a separate HAL event handler like ivman. This works independently without the need of a desktop environment, so will work no matter what runlevel (assuming it is started in that runlevel, obviously).

Unfortunately Slackware does not currently include ivman, so you will need to compile it yourself unless for can find a binary package for it someplace (LinuxPackages.net does not seem to have it). There is a SlackBuild for it, at least.
 
Old 07-23-2007, 12:45 AM   #3
rworkman
Slackware Contributor
 
Registered: Oct 2004
Location: Tuscaloosa, Alabama (USA)
Distribution: Slackware
Posts: 2,559

Rep: Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351
Good post, MS3FGX - someone want to sticky this one? I think it's a good candidate. Alternatively, perhaps a link to this in my already-stickied HAL post would be good.
 
Old 09-14-2007, 04:09 PM   #4
adriv
Member
 
Registered: Nov 2005
Location: Diessen, The Netherlands
Distribution: Slackware 15
Posts: 700

Rep: Reputation: 43
Quote:
Originally Posted by MS3FGX View Post
HAL does not actually mount anything, or even do anything with connected devices, that is a popular misconception. What HAL actually does is inform the system that a device has been connected to the system, it is up to some software application on the system to be listening for that announcement and act accordingly (in this case, mount the file system on the device). KDE is handling that for you, so once you are outside of X, it no longer happens. HAL is still doing it's thing, but nobody is listening anymore.

To rectify this you need to use a separate HAL event handler like ivman. This works independently without the need of a desktop environment, so will work no matter what runlevel (assuming it is started in that runlevel, obviously).

Unfortunately Slackware does not currently include ivman, so you will need to compile it yourself unless for can find a binary package for it someplace (LinuxPackages.net does not seem to have it). There is a SlackBuild for it, at least.
Do you NEED ivman when you're not in X?
I can't seem to mount CD's before starting X...

Last edited by adriv; 09-14-2007 at 04:13 PM.
 
Old 09-14-2007, 04:38 PM   #5
dive
Senior Member
 
Registered: Aug 2003
Location: UK
Distribution: Slackware
Posts: 3,467

Rep: Reputation: Disabled
Ivman will work in or out of X. An alternative is autofs. I use both those and HAL in kde with no problems at all. Each one works fine depending on how you set them up. I use autofs for auto mounting when I cd into a cd/dvd/phone/thumbdrive from console. Ivman works great for autoplaying DVDs which kde refuses to do properly, and in kde I can just plug in a thumbdrive and open it as a folder or cd into it with terminal.

Last edited by dive; 09-14-2007 at 04:41 PM.
 
Old 09-14-2007, 05:01 PM   #6
adriv
Member
 
Registered: Nov 2005
Location: Diessen, The Netherlands
Distribution: Slackware 15
Posts: 700

Rep: Reputation: 43
I believe you when you say it works, but is it really necessary?
I mean, suppose X won't start and I want to install a package from a Slackware CD. And ivman is not installed.
How do you do that? Since HAL won't let you mount the 'old-fashioned' way.
I know you can disable HAL and uncomment the line in fstab for cdrom, but that seems like an ugly work-around to me.
Is there another way (out-of-the-box)?
 
Old 09-14-2007, 05:27 PM   #7
dive
Senior Member
 
Registered: Aug 2003
Location: UK
Distribution: Slackware
Posts: 3,467

Rep: Reputation: Disabled
mount -t ?
 
Old 09-14-2007, 08:56 PM   #8
rworkman
Slackware Contributor
 
Registered: Oct 2004
Location: Tuscaloosa, Alabama (USA)
Distribution: Slackware
Posts: 2,559

Rep: Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351
Quote:
Originally Posted by adriv View Post
I believe you when you say it works, but is it really necessary?
I mean, suppose X won't start and I want to install a package from a Slackware CD. And ivman is not installed.
How do you do that? Since HAL won't let you mount the 'old-fashioned' way.
I know you can disable HAL and uncomment the line in fstab for cdrom, but that seems like an ugly work-around to me.
Is there another way (out-of-the-box)?
WHERE did this idea that "HAL won't let you mount the 'old-fashioned' way" come from? I'd like to find the individual responsible for that and tenderize them with a clue-cleaver.
 
Old 09-15-2007, 09:02 AM   #9
onebuck
Moderator
 
Registered: Jan 2005
Location: Central Florida 20 minutes from Disney World
Distribution: SlackwareŽ
Posts: 13,922
Blog Entries: 44

Rep: Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158
Quote:
Originally Posted by rworkman View Post
<snip> I'd like to find the individual responsible for that and tenderize them with a clue-cleaver.
Hi,

I don't think that the udev rules will allow that!


Edit: I was joking about the last sentence that robby posted. I forgot to snip the other. Sorry for mistake.

Last edited by onebuck; 09-15-2007 at 05:39 PM. Reason: Correction!
 
Old 09-15-2007, 12:20 PM   #10
rworkman
Slackware Contributor
 
Registered: Oct 2004
Location: Tuscaloosa, Alabama (USA)
Distribution: Slackware
Posts: 2,559

Rep: Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351
For those who want binary packages and don't care to use the "popular" package site, I put ivman and pmount packages in my repo last night. Enjoy! :-)
 
Old 09-15-2007, 05:06 PM   #11
adriv
Member
 
Registered: Nov 2005
Location: Diessen, The Netherlands
Distribution: Slackware 15
Posts: 700

Rep: Reputation: 43
Quote:
Originally Posted by dive View Post
mount -t ?
Nope...
Quote:
Originally Posted by rworkman View Post
WHERE did this idea that "HAL won't let you mount the 'old-fashioned' way" come from? I'd like to find the individual responsible for that and tenderize them with a clue-cleaver.
Ehmmm, it just don't work like it used to be.
Quote:
Originally Posted by onebuck View Post
I don't think that the udev rules will allow that!
Don't know what the exact cause is (not a programmer, just a hobbyist), but since HAL came along, well...
Quote:
Originally Posted by rworkman View Post
For those who want binary packages and don't care to use the "popular" package site, I put ivman and pmount packages in my repo last night. Enjoy! :-)
Thank you very much!
So I guess there is no other way to achieve what I want, without ivman/uncomment the line in fstab?

Last edited by adriv; 09-15-2007 at 05:07 PM.
 
Old 09-15-2007, 05:35 PM   #12
dive
Senior Member
 
Registered: Aug 2003
Location: UK
Distribution: Slackware
Posts: 3,467

Rep: Reputation: Disabled
Quote:
Originally Posted by adriv View Post
Thank you very much!
So I guess there is no other way to achieve what I want, without ivman/uncomment the line in fstab?
autofs http://www.linuxpackages.net/pkg_details.php?id=8957
 
Old 09-15-2007, 05:50 PM   #13
onebuck
Moderator
 
Registered: Jan 2005
Location: Central Florida 20 minutes from Disney World
Distribution: SlackwareŽ
Posts: 13,922
Blog Entries: 44

Rep: Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158Reputation: 3158
Quote:
Originally Posted by adriv View Post
Nope...

Ehmmm, it just don't work like it used to be.

Don't know what the exact cause is (not a programmer, just a hobbyist), but since HAL came along, well...

Thank you very much!
So I guess there is no other way to achieve what I want, without ivman/uncomment the line in fstab?
Hi,

Sorry if you mistook my post. I was joking with robby about his cleaver statement. The udev rules are very important.

I put a reference to link#2 of this thread in the HAL section a 'HAL definition' by MS3FGX within the 'Slackware-Links' which was compiled from 'Slackware LQ Suggestions Links!'.
 
Old 09-15-2007, 06:20 PM   #14
BCarey
Senior Member
 
Registered: Oct 2005
Location: New Mexico
Distribution: Slackware
Posts: 1,639

Rep: Reputation: Disabled
Quote:
Originally Posted by adriv View Post
Ehmmm, it just don't work like it used to be.
What happens (or doesn't happen) when you try to do it the "old-fashioned way"?

Brian
 
Old 09-15-2007, 06:25 PM   #15
T3slider
Senior Member
 
Registered: Jul 2007
Distribution: Slackware64-14.1
Posts: 2,367

Rep: Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843
I just tried mounting a CD from the console the old-fashioned way by typing the following (as root, since I haven't given my user account permission to mount/unmount):
Code:
$ mount /dev/hda /mnt/cdrom
And it worked perfectly. I didn't have to pass a single option. Wow that's simple. To further prove that HAL doesn't interfere with mounting in any way whatsoever I started X with the CD already in the drive (so KDE wouldn't pop up anything asking me what to do with the CD once I inserted it) and made sure it was unmounted (it was -- ie when KDE started up it didn't automount it). I then typed the exact same thing as root (using su) in a terminal and it worked perfectly.

So either you're doing something incorrectly or your system's toast.

I should also note that my CD drive is still commented out in /etc/fstab.
 
  


Reply

Tags
console, hal, mount


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
How to use HAL wesd Linux - Software 1 06-11-2007 04:00 PM
hal krusty_lab Fedora 3 10-10-2005 10:23 AM
Hal gamehack Programming 7 12-16-2004 02:03 AM
How to Run Win32 Console App in linux Console Lokie Linux - Software 2 08-12-2004 10:00 PM
X server in console 1 crashes on return from console 2 fieldmethods Red Hat 4 09-05-2003 12:12 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 04:17 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