Sponsored Content
Top Forums UNIX for Beginners Questions & Answers Linux Containers - /proc mounting and other queries Post 303027076 by sreyan32 on Saturday 8th of December 2018 02:11:15 AM
Old 12-08-2018
--- Post updated at 12:41 PM ---

Quote:
Originally Posted by MadeInGermany
The filesystem driver can deny a second mount. But in fact ext3, ext4, xfs allow mutiple primary mounts.
Code:
# ls -ldi /boot /mnt
     2 drwxr-xr-x  4 root root 3072 May 24  2014 /boot
260609 drwxr-xr-x  5 root root 4096 Sep 25 11:40 /mnt
# df /boot
Filesystem           1K-blocks      Used Available Use% Mounted on
/dev/sda1               101146     37017     58907  39% /boot
# mount /dev/sda1 /mnt
# ls -ldi /boot /mnt
2 drwxr-xr-x  4 root root 3072 May 24  2014 /boot
2 drwxr-xr-x  4 root root 3072 May 24  2014 /mnt
# mount | grep /dev/sda1
/dev/sda1 on /boot type ext3 (rw)
/dev/sda1 on /mnt type ext3 (rw)
# umount /mnt

The same exercise with a bind mount:
Code:
# mount --bind /boot /mnt
# ls -ldi /boot /mnt
2 drwxr-xr-x  4 root root 3072 May 24  2014 /boot
2 drwxr-xr-x  4 root root 3072 May 24  2014 /mnt
# mount | grep /dev/sda1
/dev/sda1 on /boot type ext3 (rw)
# mount | grep /mnt
/boot on /mnt type none (rw,bind)
# umount /mnt

Yes but how is a bind mount different from a normal mount?

According to this question on SO

Bind mounts reflect the directory structure from the source and does not allow modifications on the disk. Its suppose to be part of the live filesystem. But then my question is what is the difference between a normal mount?

Does this question about bind mounts deserve its own personal thread?

Your example just shows the type as none and an extra attribute as bind in the mount. What does this imply?
 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

mounting /proc or /usr

i am not quite sure what the purpose of mounting a filesystem that is already mounted.. i know you may want to mount /usr read only but do not know the true purpose behind this.. and why would /proc be mounted on /proc itself.. this is all new to me.. I have been reading up on it from various... (5 Replies)
Discussion started by: moxxx68
5 Replies

2. UNIX for Dummies Questions & Answers

CD mounting problems with linux

Hi guys I'm a newbie with linux i recently installed mandrake linux 10.0 double boot(win 98se) on a pIII 300mhz 128mb ram PC I have a standard cd rom and for some reason, linux refuses to mount the CD drive it worked perfectly for the first cople of monthes and than suddenly it didn't it... (0 Replies)
Discussion started by: bentzi
0 Replies

3. OS X (Apple)

mounting linux

firstly... sorry xDDD. now, how could i mount a linux partition on my mac os x ( i assume ill use terminal). i begins... i have my ubuntu linux partition on disk0s4. i tried: sudo mount /dev/disk0s4 /Volumes/Ubuntu and the system told me ;), "mount: exec /usr/sbin/mount_ext for... (1 Reply)
Discussion started by: Jariya
1 Replies

4. Red Hat

mounting ISO in linux

Hi Guys, I'm having a bit of trouble and im not sure what is the deal, I'm trying to mount an ISO on my RHEL box and it is not letting me... mount -o loop -t iso9660 /home/bgalante/rhel-5-server-i386-disc3.iso /mnt mount: Not a directory any idea what i am doing wrong? (2 Replies)
Discussion started by: BG_JrAdmin
2 Replies

5. Linux

Kernal panic error& setuproot:error mounting /proc&/sys

Hi all, I am new to redhat/fedora linux. In fedora linux 6,we created one file system(hda3 - /fs). in this mount poing we were installed mounta vista os. while booting we are getting below error messages. 1) Booting 'mountaVisat(2.6.18_pro 500_pc_target-x86_586 smp)' root(hd0,1)... (2 Replies)
Discussion started by: arjunreddy3
2 Replies

6. UNIX for Dummies Questions & Answers

_/proc/stat vs /proc/uptime

Hi, I am trying to calculate the CPU Usage by getting the difference between the idle time reported by /proc/stat at 2 different intervals. Now the 4th entry in the first line of /proc/stat will give me the 'idle time'. But I also came across /proc/uptime that gives me 2 entries : 1st one as the... (0 Replies)
Discussion started by: coderd
0 Replies

7. Linux

Tripwire Nightware on Linux (proc filesystem)

Hello, I am having a nightmare with Tripwire on Linux..... I cannot get it to ignore the /proc filesystem, which I want to completely ignore for now Has anyone here successfully configured Tripwire on Linux and completed ignored the /proc filesystem ? If so, please reply and tell me how... (0 Replies)
Discussion started by: Neo
0 Replies

8. Programming

Linux 11.2 to 10.2 Proc Compile error

I am trying to compile a proc++ program on linux using an 11.2 client and pointing to a 10.2 database running on Solaris. The compiler is able to connect to the database but the semantic checks fail as if it cannot see any objects in the database. I tried a test, only selecting 'X' into a... (0 Replies)
Discussion started by: rdudash
0 Replies

9. IP Networking

IP Address Linux Containers

Hello All, Please, i have a problem i try to find a solution since days i'm a beginner with linux (networking) In our cluster (10 nodes), we deploy the same image file on each node. So each node has a different ip address. In each image, there are several LXC containers. When I deploy the... (0 Replies)
Discussion started by: chercheur111
0 Replies

10. Red Hat

Looking for equivalent of Solaris containers/zones in RHEL7 Linux

Hi, I come from a legacy Solaris background with lots of experience with Solaris Containers/zones that we use for network and process isolation from each other. Currently we have a RHEL7 Linux VM running on VMWare, but we would like to segment that VM with some form of containers and achieve... (1 Reply)
Discussion started by: ckmehta
1 Replies
installgrub(1M) 														   installgrub(1M)

NAME
installgrub - install GRUB in a disk partition or a floppy SYNOPSIS
/sbin/installgrub [-fm] stage1 stage2 raw-device The installgrub command is an -only program. GRUB stands for GRand Unified Bootloader. installgrub installs GRUB stage 1 and stage 2 files on the boot area of a disk partition. If you specify the -m option, installgrub installs the stage 1 file on the master boot sector of the disk. The installgrub command accepts the following options: -f Suppresses interaction when overwriting the master boot sector. -m Installs GRUB stage1 on the master boot sector interactively. The installgrub command accepts the following operands: stage1 The name of the GRUB stage 1 file. stage2 The name of the GRUB stage 2 file. raw-device The name of the device onto which GRUB code is to be installed. It must be a character device that is readable and writable. For disk devices, specify the slice where the GRUB menu file is located. (For Solaris it is the root slice.) For a floppy disk, it is /dev/rdiskette. Example 1: Installing GRUB on a Hard Disk Slice The following command installs GRUB on a system where the root slice is c0d0s0: example# /sbin/installgrub /boot/grub/stage1 /boot/grub/stage2 /dev/rdsk/c0d0s0 Example 2: Installing GRUB on a Floppy The following command installs GRUB on a formatted floppy: example# mount -F pcfs /dev/diskette /mnt # mkdir -p /mnt/boot/grub # cp /boot/grub/* /mnt/boot/grub # umount /mnt # cd /boot/grub # /sbin/installgrub stage1 stage2 /dev/rdiskette /boot/grub Directory where GRUB files reside. See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Availability |SUNWcsu | +-----------------------------+-----------------------------+ |Interface Stability |Evolving | +-----------------------------+-----------------------------+ boot(1M), fdisk(1M), fmthard(1M), kernel(1M), attributes(5) Installing GRUB on the master boot sector (-m option) overrides any boot manager currently installed on the machine. The system will always boot the GRUB in the Solaris partition regardless of which fdisk partition is active. 24 May 2005 installgrub(1M)
All times are GMT -4. The time now is 03:48 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy