LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > SUSE / openSUSE
User Name
Password
SUSE / openSUSE This Forum is for the discussion of Suse Linux.

Notices


Reply
  Search this Thread
Old 01-06-2007, 01:01 AM   #1
sgmeunier
Member
 
Registered: Jun 2006
Location: The Netherlands
Distribution: opensuse 11.1, opensolaris 2009.06
Posts: 36

Rep: Reputation: 18
Static mount points in opensuse 10.2


I want to configure hal to mount to a static mount point. I've tried doing it the way that it is done in 10.1 (via a file mountpoints.fdi in /usr/share/hal/fdi/policy/95userpolicy/) but that doesn't seem to work. All my searches have come up empty this far. If anyone knows how to do this, an answer would be greatly appreciated since dynamic mount points really irritate me.
 
Old 01-15-2007, 03:12 PM   #2
sgmeunier
Member
 
Registered: Jun 2006
Location: The Netherlands
Distribution: opensuse 11.1, opensolaris 2009.06
Posts: 36

Original Poster
Rep: Reputation: 18
I decided to delete the file I created (mountpoints.fdi) and try it again. This time it worked like it was supposed to. There might have been a typo in the original file to prevent it from working, although I didn't pick up on one. At least it works now...
 
Old 01-15-2007, 06:12 PM   #3
TomalakBORG
Member
 
Registered: Dec 2004
Posts: 245

Rep: Reputation: 30
sgmeunier - what did you do exactly? I am curious as to how I can get /dev/sda1 to automount to /media/filevault every single time - it's an external hard drive that never leaves this machine.

What about autofs? I was looking at /etc/auto.master and auto.misc but couldn't get anything to work. Thanks in advance!

Bill
 
Old 01-30-2007, 04:52 AM   #4
pajoe
Member
 
Registered: May 2005
Location: South Central Pennsylvania
Distribution: Kubuntu 12.04
Posts: 41

Rep: Reputation: 15
could you post a copy of the file you created?

Quote:
Originally Posted by sgmeunier
I want to configure hal to mount to a static mount point. I've tried doing it the way that it is done in 10.1 (via a file mountpoints.fdi in /usr/share/hal/fdi/policy/95userpolicy/) but that doesn't seem to work. All my searches have come up empty this far. If anyone knows how to do this, an answer would be greatly appreciated since dynamic mount points really irritate me.

Could you post your copy, I am having trouble as well and I suspect it is where I enter the mount in the merge key


/usr/share/hal/fdi/policy/95userpolicy/mountpoints.fdi

<?xml version="1.0" encoding="ISO-8859-1"?> <!-- -*- SGML -*- -->
<deviceinfo version="0.2">
<device>
<!-- optical drives -->
<match key="block.device" string="/dev/hdc">
<match key="volume.is_disc" bool="true">
<merge key="volume.policy.should_mount" type="bool">true</media/cdrom>
<merge key="volume.policy.desired_mount_point" type="string">cdrom</media/cdrom>
</match>
</match>
</device>
</deviceinfo>


*********************

Procedure

As root, create a file with a file name of your liking and the ending .fdi in in /usr/share/hal/fdi/95userpolicy/. (For 10.0 this is /usr/share/hal/fdi/policy/95userpolicy/.) Example:

mountpoints.fdi

Edit the file with an editor of your choice, e.g. for a CD-ROM drive:

<?xml version="1.0" encoding="ISO-8859-1"?> <!-- -*- SGML -*- -->
<deviceinfo version="0.2">
<device>
<!-- optical drives -->
<match key="block.device" string="/dev/hdc">
<match key="volume.is_disc" bool="true">
<merge key="volume.policy.should_mount" type="bool">true</merge>
<merge key="volume.policy.desired_mount_point" type="string">cdrom</merge>
</match>
</match>
</device>
</deviceinfo>

Adapt the following lines to your system values:

<match key="block.device" string="/dev/hdc">

-> Replace /dev/hdc with the address of your CD-ROM drive.

<merge key="volume.policy.desired_mount_point" type="string">cdrom</merge>

-> Enter the mount point you desire.

After customizing the file, execute the following command as root:

rchal restart




Thanks in advance


joe
 
Old 02-13-2007, 05:56 PM   #5
inigo
LQ Newbie
 
Registered: Jun 2003
Posts: 2

Rep: Reputation: 0
Thumbs up Problem solved for 10.2

Hi everybody,

I think I found the problem, or rather the two problems:
  1. As mentioned elsewhere, the mountpoint you are going to use should not exist: Make sure there is no directory with that name. In my example below, it's /media/dvd.
  2. The fdi file mentioned before had an SGML comment in the first line. While this worked for SuSE <=10.1, this causes
    problems in 10.2, making HAL quietly ignore automounts altogether...
Here is my version of the fdi file (to mount DVDs to the static mount point /media/dvd - adjust for your own use), save it as /usr/share/hal/fdi/*/95-userpolicy.fdi (where * can be either 10osvendor, or maybe more appropriately 20thirdparty):
Code:
<?xml version="1.0" encoding="UTF-8"?>

<deviceinfo version="0.2">
    <device>
        <!-- optical drives -->
        <match key="block.device" string="/dev/sr0">
          <match key="volume.is_disc" bool="true">
            <merge key="volume.policy.should_mount" type="bool">true</merge>
            <merge key="volume.policy.desired_mount_point" type="string">dvd</merge>
          </match>
        </match>
    </device>
</deviceinfo>
After restarting HAL with 'rchal restart', it should work!

Cheers!
 
Old 02-14-2007, 04:08 AM   #6
pajoe
Member
 
Registered: May 2005
Location: South Central Pennsylvania
Distribution: Kubuntu 12.04
Posts: 41

Rep: Reputation: 15
nice work inigo, thanks
 
  


Reply

Tags
automount, hal, mount, mountpoint, opensuse, static



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
need help with mount points! rmanocha Linux - Hardware 2 10-26-2003 03:23 PM
help with mount points rmanocha Linux - Software 12 10-26-2003 01:32 PM
SCRIPT: check if auto-mount mount-points are still mounted markus1982 Linux - Software 0 05-25-2003 05:48 AM
Mount Points? Mr_Floppy4 Linux - General 2 10-14-2002 10:03 PM
mount points... Jeffrey Linux - General 6 02-24-2001 12:09 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > SUSE / openSUSE

All times are GMT -5. The time now is 06:39 PM.

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