LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > CentOS
User Name
Password
CentOS This forum is for the discussion of CentOS Linux. Note: This forum does not have any official participation.

Notices


Reply
  Search this Thread
Old 03-17-2022, 09:07 AM   #1
ppeto
LQ Newbie
 
Registered: Mar 2022
Posts: 1

Rep: Reputation: 0
I have a problem mount a new disk


I have done all the explanations

Quote:

[root@PAR-363195 ~]# lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
sda 8:0 0 931.5G 0 disk
├─sda1 8:1 0 512M 0 part /boot
├─sda2 8:2 0 925.1G 0 part /
└─sda3 8:3 0 1G 0 part [SWAP]
sdb 8:16 0 931.5G 0 disk
└─sdb4 8:20 0 931.5G 0 part This is the new hard
But it will not appear here

Quote:
[root@PAR-363195 ~]# df -Th
Filesystem Type Size Used Avail Use% Mounted on
devtmpfs devtmpfs 7.8G 0 7.8G 0% /dev
tmpfs tmpfs 7.8G 0 7.8G 0% /dev/shm
tmpfs tmpfs 7.8G 8.7M 7.8G 1% /run
tmpfs tmpfs 7.8G 0 7.8G 0% /sys/fs/cgroup
/dev/sda2 ext4 911G 1.5G 863G 1% /
/dev/sda1 ext4 488M 121M 332M 27% /boot
tmpfs tmpfs 1.6G 0 1.6G 0% /run/user/0

What do I do to appear here?
I also want to merge it with the old hard drive, how is that?
 
Old 03-17-2022, 09:46 AM   #2
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,761

Rep: Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931
What version of CentOS are you running?
Is this a physical or virtual system?

To get it to appear in the output of df you need to:

Format it with a filesytem if not already accomplished.

Mount the filesystem.

Add a line to your /etc/fstab to automatically mount it a boot time.

You can not easily merge drives together unless you are already using LVM.
 
1 members found this post helpful.
Old 04-02-2022, 10:24 AM   #3
phanthaihuan
LQ Newbie
 
Registered: Jan 2010
Location: Vietnam
Distribution: RHEL, CentOS, Debian, Ubuntu
Posts: 8

Rep: Reputation: 0
Smile

Quote:
Originally Posted by michaelk View Post
What version of CentOS are you running?
Is this a physical or virtual system?

To get it to appear in the output of df you need to:

Format it with a filesytem if not already accomplished.

Mount the filesystem.

Add a line to your /etc/fstab to automatically mount it a boot time.

You can not easily merge drives together unless you are already using LVM.
To be honest, I'm not recommend to add a line to /etc/fstab to automatically mount at boot time for non-root disk. If the disk has problem, we have trouble when booting. Non-root disks should be mount after the system booting successfully.

Best regards,
Huan Phan
 
Old 04-02-2022, 11:50 AM   #4
rknichols
Senior Member
 
Registered: Aug 2009
Distribution: Rocky Linux
Posts: 4,783

Rep: Reputation: 2214Reputation: 2214Reputation: 2214Reputation: 2214Reputation: 2214Reputation: 2214Reputation: 2214Reputation: 2214Reputation: 2214Reputation: 2214Reputation: 2214
Quote:
Originally Posted by phanthaihuan View Post
To be honest, I'm not recommend to add a line to /etc/fstab to automatically mount at boot time for non-root disk. If the disk has problem, we have trouble when booting. Non-root disks should be mount after the system booting successfully.
All you have to do is include "nofail" in the options field, and the mount failure will not block booting. Alternatively, use "noauto" instead, and the drive will not be mounted automatically, but a manual mount command with just the device name or the mount point (not both) will pick up all the other parameters from /etc/fstab.
 
Old 04-03-2022, 08:42 PM   #5
phanthaihuan
LQ Newbie
 
Registered: Jan 2010
Location: Vietnam
Distribution: RHEL, CentOS, Debian, Ubuntu
Posts: 8

Rep: Reputation: 0
Quote:
Originally Posted by rknichols View Post
All you have to do is include "nofail" in the options field, and the mount failure will not block booting. Alternatively, use "noauto" instead, and the drive will not be mounted automatically, but a manual mount command with just the device name or the mount point (not both) will pick up all the other parameters from /etc/fstab.
Thank you for the information
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
I have an old laptop[8yrs] and I have tried to operate a Fedora 16 program alas I have no idea what my root ID is or my passwords. need to dickidido Linux - Newbie 6 03-10-2016 04:08 PM
new hdd, old mount needs to point to new hdd mount. phorning Linux - Newbie 3 06-14-2010 05:44 AM
Do I have to have static IP assignment to auto-mount Samba shares? buccaneere Linux - Networking 1 03-31-2009 12:29 PM
Mount. Umount. Mount. Umount. Mount. Umount. Mount.. cwizardone Slackware 10 03-22-2007 09:30 AM
floppy only reads first disk, if new disk is inserted data from first disk is shown. lakosked Debian 3 02-18-2006 08:44 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > CentOS

All times are GMT -5. The time now is 12:54 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration