using chroot
excuse me,
I don't know how to use chroot to change root of a file. For example, I see that when I run ls -la in /etc, it shows something like resolve.conf -> /etc/resolveconf/run/resolve.conf so the orginal file is /etc/resolveconf/run/resolve.conf, right? how can I do like that? can anybody show me how to do :-?? thanks! |
I don't fully understand what you're asking. Are you asking how to create a symbolic link? If so, use ln -s:
Code:
~$ touch file |
oh really, so does chroot have anything to do with it?
|
No - chroot changes the root directory used for a command.
So e.g. if you have 2 linux distros installed, and the root filesystem of the inactive one is mounted at /mnt/distro2, you can execute Code:
chroot /mnt/distro2 |
so the ln -s makes the file name have the white color (in redhat or fedora), while the original file has white colour. is that true?
|
Colour has nothing to do with it. ln -s creates a new file which is simply a pointer to the target file - see here and here.
Are you talking about the colours in the output of ls? These are determined by the environment variable $LS_COLORS, which is usually set in some startup or profile file in /etc. echo $LS_COLORS will tell you whether or not this variable is set. |
ah yea, got it. thanks alot :D
|
All times are GMT -5. The time now is 12:24 AM. |