OESF | ELSI | pdaXrom | OpenZaurus | Zaurus Themes | Community Links | Ibiblio

IPB

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> Symlink /home To /mnt/ide2/home
climber
post Mar 5 2007, 12:48 AM
Post #1





Group: Members
Posts: 193
Joined: 21-November 05
Member No.: 8,574



Hi,

I want to create the following symlink:

/home is a symlink of /mnt/ide2/home


What I did:

- copy the whole /home directory to /mnt/ide2/home
- Create symlink: ln -s /mnt/ide2/home/ /home


When I do a reboot I get the following error message:

Module dependencies: OK
mount: special device /hom/user does not exist

I think I did not all entries but I don't know where and which to do to fix this problem.

Can anybody help me?


Thanks
climber

SL-C3100 with pdaXrom beta3
Go to the top of the page
 
+Quote Post
Capn_Fish
post Mar 5 2007, 07:34 AM
Post #2





Group: Members
Posts: 2,350
Joined: 30-July 06
Member No.: 10,575



Did you copy hidden stuff? I probably can't help, but I can weed out simple solutions for those who can.
Go to the top of the page
 
+Quote Post
Chero
post Mar 5 2007, 10:50 AM
Post #3





Group: Members
Posts: 1,141
Joined: 22-April 04
From: Belgium
Member No.: 2,962



Do you actually have a problem - apart from the error message ?

I thought this message came from the "one-partition-setup".
Correct me if I'm wrong.

Chero.
Go to the top of the page
 
+Quote Post
speculatrix
post Mar 5 2007, 01:46 PM
Post #4





Group: Admin
Posts: 3,281
Joined: 29-July 04
From: Cambridge, England
Member No.: 4,149



do the pdaXrom startup scripts act like those in sharp or cacko, which attempt to recreate the home directory if the /home/zaurus/Documents directory doesn't exist?

I tried moving /home/zaurus/Documents elsewhere and symlinking in, using cacko1.23 on my 3100 and the startup scripts tried to remove the symlink and fix things, but actually broke it completely!
Go to the top of the page
 
+Quote Post
Drake01
post Mar 5 2007, 07:24 PM
Post #5





Group: Members
Posts: 226
Joined: 29-March 06
Member No.: 9,483



QUOTE(climber @ Mar 5 2007, 03:48 AM)
mount: special device /hom/user  does not exist

I think I did not all entries but I don't know where and which to do to fix this problem.

Can anybody help me?
*

I'm not an expert on Linux, but on my desktop and my Zaurus, /home is mounted. It's not just a simple directory; the system is actually mounting it. I don't believe you can simply symlink it. I think you'd have to find what is mounting it and change that script.

I would suggest changing /etc/fstab, but I've heard that this doesn't always work as one would expect in pdaXrom.
Go to the top of the page
 
+Quote Post
Meanie
post Mar 5 2007, 07:31 PM
Post #6





Group: Members
Posts: 2,808
Joined: 21-March 05
From: Sydney, Australia
Member No.: 6,686



as I have mentioned before in some other post, the best would be to bind the directory instead:


mount --bind /mnt/ide2/home /home
Go to the top of the page
 
+Quote Post
climber
post Mar 6 2007, 12:30 AM
Post #7





Group: Members
Posts: 193
Joined: 21-November 05
Member No.: 8,574



Chero: No I have only the error message on booting but everything works after.

Meanie: That could be also a solution and maybe the better one! Where should I put in your code to bind it automatically?

Thanks
climber
Go to the top of the page
 
+Quote Post
climber
post Mar 9 2007, 03:26 AM
Post #8





Group: Members
Posts: 193
Joined: 21-November 05
Member No.: 8,574



Meanie,

could you help me please because I tried so many things without success!

Where should I put in your code to bind it automatically?

Thanks
climber
Go to the top of the page
 
+Quote Post
daniel3000
post Mar 9 2007, 06:40 AM
Post #9





Group: Members
Posts: 1,002
Joined: 28-April 05
From: Germany
Member No.: 7,027



QUOTE(climber @ Mar 9 2007, 01:26 PM)
Meanie,

could you help me please because I tried so many things without success!

Where should I put in your code to bind it automatically?

Thanks
climber
*


Hi Climber,

because I also did a similar thing recently, I can tell you:

Put this into a script called /etc/rc.d/init.d/mountbind:

CODE
#!/bin/sh
. /etc/rc.d/init.d/functions
COUNTER=0

case "$1" in
 start)
    while [ ! -d /mnt/ide2/home ]; do
 sleep 1
 COUNTER=$[$COUNTER+1]
 if [ $COUNTER -gt 45 ]; then
   echo /mnt/ide2/home does not become available!
   echo Cannot bind /home!
   echo Please try removing any CF cards and reboot.
   echo Or did /mnt/ide2/home get deleted or corrupted?
   action "Binding home from HDD:" mount --bind /mnt/ide2/home /home
   exit 1
 fi
    done
    action "Binding home from HDD:" mount --bind /mnt/ide2/home /home
;;
 stop)
;;
esac
exit 0


As you see, this uses the same looped detection mechanism as I suggested for your swap issue in z-portal.info. :-)
In fact, this is the problem what I used that for initially.

Once more for the OESF people:

Sometimes, the devices (SD or CD cards) don't get available quickly enough in order to let subsequent rc scripts use the devices.
For example, when there is a CF WLAN card inserted, the microdrive initialization is so slow, that a script liek the one above, albeit executed as the last script in the rc sequence, cannot access the microdrive.
Hence the need for that loop.
It checks each second if the directory (and hence the device) in question is available and only THEN runs the actual action.

Why two occurrecnces of the action? The purpose is that the user gets the red "FAILED" message in the timeout case.
Of course, one could leave away the "exit 1" instead and make te script even more elegant with an error state variable and conditional exit value at the end... :-)


Oh, and link this script to rcX.d (X=1..5) as "S60mountbind".
Otherwise it won't be executed ;-)
Also, be sure to make the script executable.

daniel
Go to the top of the page
 
+Quote Post
climber
post Mar 15 2007, 02:21 AM
Post #10





Group: Members
Posts: 193
Joined: 21-November 05
Member No.: 8,574



Daniel,

thank you for your answer. It works very well !!! :-)

Regards
climber
Go to the top of the page
 
+Quote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



RSS Lo-Fi Version Time is now: 20th October 2014 - 01:14 PM