Questions about what 'mount' does
While working on an SBC (TS 7200) running Red Hat, I entered the following:
mount /dev/mtdblock/1 /mnt So far I understand I've mounted my filesystem (happened to be that particular partition) over again but now in /mnt. However, now all my files/directories are appended with the same characters. An example snippet: (here's a snippet of my /bin directory) $ ls /bin 1;36maddgroup0m 1;36mdd0m 1;36mgunzip0m 1;36mmknod0m 1;36 mrm0m 1;36mtrue0m 1;36madduser0m 1;36mdelgroup0m 1;36mgzip0m 1;36mmktemp0m 1;36 mrmdir0m 1;36mumount0m 1;36mash0m 1;36mdeluser0m 1;36mhostname0m 1;36mmore0m 1;36 msed0m 1;36muname0m Everything has 1;36m and 0m at the beginning and end, respectively. I'm curious as to what it means, and more importantly, how to get rid of it. Thanks, Joe |
What shell are you running? That looks like your colours are screwed. Edit ~/.bashrc and remove the ls alias for a temporary solution.
|
You are trying to mount a local partition, right? I have never seen such device designations. Usually, its /dev/hda1 (first partition, first ATA hard drive) or /dev/sdb2 (second partition on the second SCSI hard drive).
|
Quote:
1;36 is the code for the cyan color. It's the default color for soft links. (at least in slack). I think DJ P@CkMaN is right. Instead of removing the ls alias try this first: Code:
\ls /bin |
Unfortunately, I did try your trick and everything is still listed as so. I'm also not quite sure where the .bashrc file is located. I also believe i'm running bourne shell.
Thanks again Joe |
Quote:
I don't know if the \ before a command is only for bash, but it's supposed to run the real command (ls) ignoring any existing allias. The .bashrc is in the home directory of the user, but not all distros use it. Slackware only use ~/.profile (for each user) and /etc/profile (for all users). What distro are you using? What is the output of this: Code:
echo -e "\033[1;36mhello\033[0m" Also, can you post us the output of printenv command? |
Running Red Hat.
Here's the first output: Code:
$ echo -e "/033[1;36mhello\033[0m" Code:
$ printenv Joe |
hello,
you made a mistake: that's not echo -e "/033[1;36mhello\033[0m" but that's echo -e "\033[1;36mhello\033[0m" and if it works, it should print hello in cyan color ;) and if printenv does not work, try env command :) Oliv' |
Code:
$ echo -e "\033[1;36mhello\033[0m" Code:
$ env Joe |
You might be using sh, and then again, you might not. Many distros symlink /bin/sh to /bin/bash. To verify, do this:
ls /bin/sh If your output looks like this: /bin/sh -> bash, then you are using bash. |
Quote:
ALso u need to do Code:
ls -l /bin/sh In SuSE the ls for root is an allias to ls -la....something I think. This is why a simple root ls outputs in long format, including hidden files. |
[/CODE]$ ls -l /bin/sh
lrwxrwxrwx 1 root root 7 Mar 1 2005 1;36m/bin/sh0m -> 1;32mb usybox0m[/CODE] The distro should not be very old at ALL, I just bought this board last week, and the version of Red Hat it came with should be the most up-to-date. Joe |
Quote:
I had to search the net to see what this thing is. Why don't you just time bash in the console to see what happens with the colors. |
busybox: that's a sort of tiny bash... it's widely used in embedded systems with µlibc (or at least light libc)
|
Quote:
Code:
$ time bash Code:
$ ls -l /bin/sh Thanks a million, Joe Joe |
All times are GMT -5. The time now is 12:59 PM. |