what is the difference between /etc/mnttab and /etc/vfstab

what is the difference between /etc/mnttab and /etc/vfstab???? what are these files used for

one time i removed mnttab file from my solaris box. infact i renamed it and my solaris box was not booting properly.

/etc/vfstab contains definitions of filesystem that can be mounted (at boot or later manually). It is maintained by system administrator.
/etc/mnttab contains list of filesystems that are already mounted. It is maintained by kernel and shouldn't be touched by anyone.

1 Like

Thanks for the quick response mate.. can i change the permissions for mnttab? i tried but it didnt allow me to do it. i logged in as root .

Why would you want to do that? Solaris is protecting this file, so it will refuse to change permission rights for it.

bartus11 i am newbie. i have installed vmware and have installed solaris in it. with this setup i can take all risks. so that i can learn from my mistakes which wont create a problem. i mean i can make a mistake that wont harm anyone. :slight_smile:

so is there any way to change the permission?

i have few doubts about vmware also can you help me with that also?

Thanks in advance

I think you could boot your Solaris host from CD, then mount root slice and change permissions there, then reboot. But I think you won't notice the change after reboot, as /etc/mnttab is a mountpoint for mnttab memory based filesystem (after mounting it by the system, permissions on the mountpoint change to those of the mounted FS).

i will try that. and regarding vmware doubts? can i ask about them to you

Shoot. I didn't use VMware much, but maybe I'll know the answer to your problems.

i have set a hostname to my vmware solaris box. and i am trying to ping it from my windows xp machine. but its not working. when i try to ping using its IP its working. but when i try to ping with its hostname its not working. how to fix this? any suggestions?

Add an entry for your Solaris host in the form of

ip_address hostname

to C:\WINDOWS\system32\drivers\etc\hosts on your Windows machine.

On Solaris 10 at least, /etc/mnttab is now a separate filesystem unto itself. This allows the kernel to ensure that it is never out of date.

$ uname -a
SunOS geo-support1 5.10 Generic_127111-10 sun4u sparc SUNW,Sun-Blade-1000
$ df -k /etc/mnttab
Filesystem            kbytes    used   avail capacity  Mounted on
mnttab                     0       0       0     0%    /etc/mnttab
$

You can list the contents of /etc/mnttab by issuing "mount" with no arguments. Note that /etc/mnttab is included...

$
$ mount
/ on /dev/dsk/c1t1d0s0 read/write/setuid/devices/intr/largefiles/logging/xattr/onerror=panic/dev=1d80008 on Sat Apr 16 17:18:49 2011
/devices on /devices read/write/setuid/devices/dev=4e00000 on Sat Apr 16 17:18:34 2011
/system/contract on ctfs read/write/setuid/devices/dev=4e40001 on Sat Apr 16 17:18:34 2011
/proc on proc read/write/setuid/devices/dev=4e80000 on Sat Apr 16 17:18:34 2011
/etc/mnttab on mnttab read/write/setuid/devices/dev=4ec0001 on Sat Apr 16 17:18:34 2011
/etc/svc/volatile on swap read/write/setuid/devices/xattr/dev=4f00001 on Sat Apr 16 17:18:34 2011
/system/object on objfs read/write/setuid/devices/dev=4f40001 on Sat Apr 16 17:18:34 2011
/platform/sun4u-us3/lib/libc_psr.so.1 on /platform/sun4u-us3/lib/libc_psr/libc_psr_hwcap1.so.1 read/write/setuid/devices/dev=1d80008 on Sat Apr 16 17:18:43 2011
/platform/sun4u-us3/lib/sparcv9/libc_psr.so.1 on /platform/sun4u-us3/lib/sparcv9/libc_psr/libc_psr_hwcap1.so.1 read/write/setuid/devices/dev=1d80008 on Sat Apr 16 17:18:45 2011
/dev/fd on fd read/write/setuid/devices/dev=5100001 on Sat Apr 16 17:18:49 2011
/tmp on swap read/write/setuid/devices/xattr/dev=4f00002 on Sat Apr 16 17:18:52 2011
/var/run on swap read/write/setuid/devices/xattr/dev=4f00003 on Sat Apr 16 17:18:52 2011
/project on /dev/dsk/c1t1d0s4 read/write/setuid/devices/intr/largefiles/logging/xattr/onerror=panic/dev=1d8000c on Sat Apr 16 17:19:01 2011
/export/home on /dev/dsk/c1t1d0s3 read/write/setuid/devices/intr/largefiles/logging/xattr/onerror=panic/dev=1d8000b on Sat Apr 16 17:19:02 2011
$

@ bartus11 .. Man your like God to me :slight_smile: now i am able to ping the solaris host from my windows. Thanks a Ton.. was googling about the issue for more than a month but didnt get a clue. i should have joined this forum before itself. its awesome.

@perderabo ... Thanks for the tip.. thats a new thing i learn from you..

P.S : instead of googling and reading books better i can visit this forum for help. Thanks both of you again. I would be happy if i get the same support from this forum in future also. I depend on my vmware to learn things but i am new to both vmware and solaris. i hope you people will help me with it. :slight_smile:

---------- Post updated at 10:17 AM ---------- Previous update was at 08:56 AM ----------

now i am able to ping my solaris box from windows. and i added the entry into /etc/hosts and now i am able to ping my windows from solaris box. thanks again for the tip.
now i am trying to login to solaris box through my putty installed in windows.
i am able to ssh to solaris host with help putty as any normal user but not as root user.

my doubt : how to ssh to solaris box as root user using putty. ?

---------- Post updated at 10:32 AM ---------- Previous update was at 10:17 AM ----------

Hi.. Got it fixed :slight_smile: enable root login in sshd_config file :slight_smile:

How can I get my tape drive to work after deleting my etc folder?