The program shlight always creates an empty /etc/mnttab file. All
mount points are working, but some commands (like df) needs a correct
/etc/mnttab file. Booting the machine recreates /etc/mnttab, but is
there a way to recreate it without booting?
I am running Solaris 9.
Thanks in advance,
Roland Scholz
|
|
0
|
|
|
|
Reply
|
rs
|
2/5/2004 3:58:30 PM |
|
Roland Scholz wrote:
> The program shlight always creates an empty /etc/mnttab file.
I don't understand how. On Solaris 8/9 /etc/mnttab isn't a file; it's a
thing that looks like a file but (through the magic of virtual
filesystems) is actually a direct representation of the kernel's mounted
filesystem table. You can't edit it (or write an edited version, at any
rate), you can't remove it, you can't over-write it with /dev/null
For instance
# cat /dev/null > /etc/mnttab
/etc/mnttab: cannot create
$ rm /etc/mnttab
rm: /etc/mnttab: override protection 444 (yes/no)? y
rm: /etc/mnttab not removed: Device busy
So I wonder what this shlight thing is doing...
> All mount points are working, but some commands (like df) needs a
> correct /etc/mnttab file. Booting the machine recreates /etc/mnttab,
> but is there a way to recreate it without booting?
Try unmounting it
# umount /etc/mnttab
then remounting it
# mount -F mntfs mnttab /etc/mnttab
--
Tony
|
|
0
|
|
|
|
Reply
|
Tony
|
2/5/2004 4:12:43 PM
|
|
In article <511b2f03.0402050758.64b6c9ec@posting.google.com>,
Roland Scholz <rs@RolandScholz.de> wrote:
>The program shlight always creates an empty /etc/mnttab file. All
>mount points are working, but some commands (like df) needs a correct
>/etc/mnttab file. Booting the machine recreates /etc/mnttab, but is
>there a way to recreate it without booting?
>I am running Solaris 9.
Unless you've done awful things to your system, /etc/mnttab in
Solaris 9 (or 8, for that matter) is a read-only view onto kernel
data. It can't be "emptied" by anyone.
So what is shlight (who he?) up to? Maybe it's done an umount(1m)
on /etc/mnttab? (In which case, mount it again, the way it's done
in /etc/rcS.d/S40standardmounts.sh.)
Chris Thompson
Email: cet1 [at] cam.ac.uk
|
|
0
|
|
|
|
Reply
|
cet1
|
2/5/2004 4:27:17 PM
|
|
Tony Walton wrote:
> So I wonder what this shlight thing is doing...
Apparently something similar to what fle-shlight does ;-)
|
|
0
|
|
|
|
Reply
|
Beardy
|
2/5/2004 5:50:25 PM
|
|
Tony Walton <tony.walton@s_u_n.com> wrote in message news:<40226B7B.7030504@s_u_n.com>...
> Roland Scholz wrote:
> > The program shlight always creates an empty /etc/mnttab file.
>
> I don't understand how. On Solaris 8/9 /etc/mnttab isn't a file; it's a
> thing that looks like a file but (through the magic of virtual
> filesystems) is actually a direct representation of the kernel's mounted
> filesystem table. You can't edit it (or write an edited version, at any
> rate), you can't remove it, you can't over-write it with /dev/null
>
> For instance
>
> # cat /dev/null > /etc/mnttab
> /etc/mnttab: cannot create
>
> $ rm /etc/mnttab
> rm: /etc/mnttab: override protection 444 (yes/no)? y
> rm: /etc/mnttab not removed: Device busy
>
> So I wonder what this shlight thing is doing...
I know that /etc/mnttab is a filesystem, but everytime I run shlight (which is
used to mount SMB file systems exported by Windows), /etc/mnttab is empty.
>
> > All mount points are working, but some commands (like df) needs a
> > correct /etc/mnttab file. Booting the machine recreates /etc/mnttab,
> > but is there a way to recreate it without booting?
>
> Try unmounting it
>
> # umount /etc/mnttab
>
> then remounting it
>
> # mount -F mntfs mnttab /etc/mnttab
Thanks, that does the trick.
:)
|
|
0
|
|
|
|
Reply
|
rs
|
2/6/2004 7:29:28 AM
|
|
|
4 Replies
1304 Views
(page loaded in 0.045 seconds)
Similiar Articles: How to remove file entries without vi or > null - comp.unix ...how to recreate empty /etc/mnttab file? - comp.unix.solaris ... What's a fast way to delete file by inode ? - comp.unix.shell ..... to remove file entries without vi or ... how to remove a stale mount point - comp.unix.solaris... area < This line left intentionally blank ... in the busy state, you have to remove it and recreate ... work this time, I fixed it by going into the /etc/mnttab file ... zone boot failed - comp.unix.solarisLooking from the zone's root directory, is the file etc/mnttab there? It looks like it isn ... Well, you can solve this by just using touch to create an empty one. But there ... No space left on device - comp.unix.solarisWhen I am using VI to edit a file, I ... 0K 0K 0K 0% /proc mnttab 0K 0K 0K 0% /etc ... This line left intentionally blank to ... Disk information - comp.unix.solaris... 0 0 0% /etc/ mnttab /dev/md/dsk/d20 1333407 ... dev/dsk/ c1d0s2 prtvtoc: /dev/dsk/c1d0s2: No such file ... use the following code to test if an dvd disk is empty. How do I create a solidworks title block from a cad title block ...Then, save as Sheet Format under the File pulldown menu. ... Click Finish Now, right mouse click on drawing empty ... settings and custom properties. ... to redraw and recreate ... importing to 11Gr2 from 9i - full import or schema's only? - comp ...One of them has only a couple of users, roles etc. so I ... the application tablespaces when I created the empty ... failed, at first I tried having it read the dmp file ... Enterprise Support - Symantec Corp. - DOCUMENTATION: Solaris 10 ...Once the zone is halted, the /zones/zone1/root/usr directory is empty: sun02:# ls ... to boot so that once the /zones/zone1 directory has been restored, the /etc/mnttab file ... Sun: Solaris - Entry not getting deleted from /etc/mnttab... got to where you are, but the /etc/mnttab file ... Try to recreate the directory and remount the filesystem, then unmount the filesystem. /etc/mnttab is a read-only ... 7/23/2012 9:50:46 PM
|