LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   How to implement this script without "devfsd"? (https://www.linuxquestions.org/questions/linux-newbie-8/how-to-implement-this-script-without-devfsd-640890/)

newtovanilla 05-08-2008 03:28 PM

How to implement this script without "devfsd"?
 
How to implement this script without "devfsd"?

# loop rescanning the scsi bus + rerunning devfsd
retries=5
i=1
until [ -e $REAL_ROOT ]
do
if [ $i -gt $retries ]
then
echo "Unable to mount real root ($REAL_ROOT) - Giving up!"
/bin/ash
exit
fi

echo "Real root ($REAL_ROOT) not found, retrying ($i)"
sleep 1
echo "scsi add-single-device 0 0 0" > /proc/scsi/scsi
echo "scsi add-single-device 1 0 0" > /proc/scsi/scsi
echo "scsi add-single-device 2 0 0" > /proc/scsi/scsi
/bin/devfsd /dev -np
i=$((i+1))
done

Nylex 05-09-2008 02:30 AM

Remove the line containing "devfsd"..

If you're trying to implement something, it's in your interests to tell us what you're trying to do..

newtovanilla 05-11-2008 04:43 AM

Thank you for the comment. I am new to Linux and new to the forum.

Does that work? I do not know what this script does. That is why I posted it to LQ. Someone gave me this solution from LQ. I am asking for a different way to implement that command. Someone must understand what that command does in the script and could tell me another way to do it.

Could someone tell me what it does and another way to do it? The command was there for some function that I do not understand.

# loop rescanning the scsi bus + rerunning devfsd

Quote:

If you're trying to implement something, it's in your interests to tell us what you're trying to do..
I am trying to find another way to implement the script without using devfsd. I thought my question was clearly written. Do you know what this script does and how to implement it without devfsd? Deleting devfsd is not a solution to my question!

colucix 05-11-2008 05:13 AM

Quote:

Originally Posted by newtovanilla (Post 3149765)
I am trying to find another way to implement the script without using devfsd. I thought my question was clearly written. Do you know what this script does and how to implement it without devfsd?

No. It is not possible to know exactly what this script do. We can only try to interpret the semantic, not the actions performed by this script if we don't know the context. Furthermore, it looks like a part of a more complex script, since the variable REAL_ROOT is not assigned anywhere.

Anyway, devfsd is a daemon for managing the device entries in the Linux Device Filesystem. It is an obsolete feature now substituted by udev in the recent kernels.

newtovanilla 05-17-2008 06:26 PM

The context for the script is in the original post. There should be enough in the script to understand what it does and to find another way to do it, if you know scripting. I do not know scripting, so that is why I posted this question. After looking on the web, it seems to me that it does not matter what the variable REAL_ROOT is, as long as it is defined. One of the posts on LQ said that you can get its value with the command "echo $REAL_ROOT".

It is off topic to explain where this script came from. If you want to know about that, look at all my other posts in LQ!

Quote:

It is an obsolete feature now substituted by udev in the recent kernels.
That is why I am asking to find another way to do this script! Does someone understand what this script does and how to implement it in recent kernels that do not use "devfsd"?

colucix 05-17-2008 06:46 PM

Quote:

Originally Posted by newtovanilla (Post 3156521)
It is off topic to explain where this script came from. If you want to know about that, look at all my other posts in LQ!

It sounds a little pretentious to ask people look at your LQ history, instead of explaining a little more in your newly opened thread. If it is related to your previous threads, continue to post there, don't start a new one pretending people knows what you're talking about or what you have in mind!

newtovanilla 05-18-2008 03:47 PM

From the other posts, this is what I am trying to do. Does this help you to tell me another way to do the script?

I was told to start new posts if I have new questions! I did what I was told by LQ members.


All times are GMT -5. The time now is 01:37 PM.