LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 08-07-2018, 01:53 PM   #1
vishnutant
LQ Newbie
 
Registered: Aug 2018
Posts: 2

Rep: Reputation: Disabled
New disk are not avaliable for the host on centos after scanning


Hi all,

i have added disks to my VM which is on ESX,after adding loggedin to the machine and did below commands
1. sudo fdisk -l
2. sudo lsblk
i am not able to find newly added disks

i have executed scan on all the hosts
echo "- - -" >sudo /sys/class/scsi_host/host#/scan

Still the disk is not avaliable
Any pointers on why the disk is not avaliable
 
Old 08-07-2018, 02:23 PM   #2
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, CoreOS, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 7,814
Blog Entries: 15

Rep: Reputation: 1661Reputation: 1661Reputation: 1661Reputation: 1661Reputation: 1661Reputation: 1661Reputation: 1661Reputation: 1661Reputation: 1661Reputation: 1661Reputation: 1661
The sudo command says to run what follows it as root. The arrow says to redirect so your original syntax was redirecting into the name "sudo" rather than executing sudo. It probably created a file named "sudo" which has "- - -" in it. If so you can safely remove that file. The correct way to do it is to start with the sudo command so try instead:

Code:
sudo echo "- - -" > /sys/class/scsi_host/host#/scan
 
Old 08-07-2018, 10:47 PM   #3
vishnutant
LQ Newbie
 
Registered: Aug 2018
Posts: 2

Original Poster
Rep: Reputation: Disabled
i tried the above command,
when i execute the command
sudo echo "- - -" > /sys/class/scsi_host/host#/scan
it errors out saying:
-bash: /sys/class/scsi_host/host0/scan: Permission denied
 
Old 08-08-2018, 02:42 AM   #4
AwesomeMachine
LQ Guru
 
Registered: Jan 2005
Location: USA and Italy
Distribution: Debian testing/sid; OpenSuSE; Fedora; Mint
Posts: 5,513

Rep: Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004
Thbe sudoer probably doesn't have permission to see that directory. Use visudo to edit it. Also, did you add the new disks to the disk controller. Try 'ls /dev/sd*'.
 
Old 08-08-2018, 11:14 AM   #5
TenTenths
Senior Member
 
Registered: Aug 2011
Location: Dublin
Distribution: Centos 5 / 6 / 7
Posts: 2,938

Rep: Reputation: 1210Reputation: 1210Reputation: 1210Reputation: 1210Reputation: 1210Reputation: 1210Reputation: 1210Reputation: 1210Reputation: 1210
Unless you have the relevant vmware tools installed in your VM you will not see any resources added to it until after a full power-down restart.

Do that to your VM and then try the commands you mentioned in the first post.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
CentOS 6 connect to host 10.1.93.101 port 50001: No route to host tim head Linux - Networking 2 08-16-2015 05:18 AM
c source code for scanning a shared directory of a host xin jo Linux - Networking 3 04-01-2011 05:14 AM
ettercap crashes during scanning for host kususe Linux - Software 3 03-07-2011 09:30 AM
Scanning Disk or Disk Repairing mhkhalqani Linux - Hardware 4 09-30-2005 09:28 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 10:19 PM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration