In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
Linux how to use the mount command to mount CDROM, many novices are not very clear about this, in order to help you solve this problem, the following editor will explain in detail for you, people with this need can come to learn, I hope you can get something.
For example, use the mount command to mount cdrom
Command:
Mount-t auto / dev/cdrom / mnt/cdrom
The command is to mount the cdrom in the / mnt/cdrom directory, where I can access the contents.
Mount command:
Homer@ubuntu: ~ $mount-t auto / dev/cdrom / mnt/cdrom
Tip: mount: only root can do that / / ordinary users cannot mount cdrom, only root users can operate it.
Switch users:
Root@ubuntu: ~ # mount-t auto / dev/cdrom / mnt/cdrom
Mount: the mount point / mnt/cdrom does not exist / mnt/cdrom directory does not exist and needs to be created first.
Root@ubuntu: ~ # mkdir-p / mnt/cdrom / / Recursive create / mnt/ CDRom subdirectory
Remount:
Root@ubuntu: ~ # mount-t auto / dev/cdrom / mnt/cdrom / / Mount cdrom
Mount: block device / dev/cdrom is write-protected, mounting read-only / / mounted successfully
Root@ubuntu: ~ # ls-l / mnt/cdrom / / View the contents of cdrom
Uninstall command:
Root@ubuntu: ~ # umount / mnt/cdrom / / it's easy to uninstall cdrom. Use umount / mnt/cdrom directly.
Mount command other parameter name: mount
Rights of use: system administrator or users allowed in / etc/fstab
Mode of use:
Mount [- hV]
Mount-a [- fFnrsvw] [- t vfstype]
Mount [- fnrsvw] [- o options [,...]] Device | dir
Mount [- fnrsvw] [- t vfstype] [- o options] device dir
Description:
Interpret the contents of a file as a file system, and then hang it on a location in the directory. When this command is successfully executed, all files under this command will not be available for the time being until we remove the file system using umnount.
This command can be used to mount any file system, and you can even use the-o loop option to mount a general file as if it were a hard drive. This feature is very useful for interpreting ramdisk,romdisk or ISO 9660 video files.
Parameters:
-V display program version
-h display auxiliary message
-v displays more messages and is usually used with-f for debugging.
-a Mount all file systems defined in / etc/fstab.
The command-F is usually used with-a, which generates a stroke for each mount action to be executed. When the system needs to hang a large number of NFS file system, you can speed up the action of hanging.
-f is usually used for debugging purposes. It causes mount not to perform the actual mount action, but to simulate the entire mount process. Usually used with-v.
-n generally speaking, mount will write a piece of data in / etc/mtab after hanging up. However, you can use this option to cancel this action if there is no writable file system in the system.
-smurr equals-o ro
-w equals-o rw
-L hangs the hard drive with a specific label on it.
-U hangs up the file system with the file division serial number. -L and-U only make sense when files such as / proc/partition exist.
-t specifies the type of file system, which is usually not required. Mount automatically selects the correct type.
-o async turns on asynchronous mode, and all file read and write actions are performed in asynchronous mode.
-o sync executes in synchronous mode.
-o atime
-o noatime when atime is opened, the last call time of the archive is updated each time the archive is read. When we use the flash file system, we may choose to turn this option off to reduce the number of writes.
-o auto
-o noauto toggles auto hang mode on / off.
-o defaults uses the default options rw, suid, dev, exec, auto, nouser, and async.
-o dev
-o nodev-o exec
-o noexec allows executable files to be executed.
-o suid
-o nosuid allows execution files to be executed under root permissions.
-o user
-o nouser users can perform mount/umount actions.
-o remount remounts a suspended file system in a different way. For example, a system that used to be read-only is now re-hung in read-write mode.
-o ro hangs in read-only mode.
-o rw hangs in read / write mode.
-o loop= uses loop mode to attach a file to the system as if it were a hard disk partition.
Example:
Hang / dev/hda1 under / mnt.
# mount / dev/hda1 / mnt
Hang / dev/hda1 under / mnt in read-only mode
# mount-o ro / dev/hda1 / mnt
Hang the image file of the CD / tmp/image.iso under / mnt/cdrom using loop mode
In this way, the contents of Linux ISO files that can be found on the network can be viewed without burning them into CDs.
# mount-o loop / tmp/image.iso / mnt/cdrom
Is it helpful for you to read the above content? If you want to know more about the relevant knowledge or read more related articles, please follow the industry information channel, thank you for your support.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.