Lỗi no such file or directory trên centos 7 năm 2024

/usr/local/bin is not in $PATH by default in CentOS. Either add it in or run yum install ImageMagick to install ImageMagick from the CentOS repos.

answered Feb 12, 2013 at 5:03

6

Don't go installing software from source unless strictly necessary. I believe ImageMagick is in CentOS, and GraphicsMagick (a fork from the above) is in EPEL

I assume this error is not exclusive of CentOS7 but it’s a general NFS error. I have a CentOS 7 server that I call server, and there, a folder called /folder that I want to make available on the client client. All very original here. Let’s do this. On the server, we prepare the export and bind our folder with it. Basically

@server> mkdir export; cd export @server> mkdir folder @server> mount --bind /folder/ /export/folder

Now we need to write our export file. Mine is looking like this

@ server> more /etc/exports

/etc/exports - a list of directories for NFS to export

/export 192.168.10.0/255.255.255.0 \ (rw,fsid=0,hide,insecure,no_subtree_check,sync,no_root_squash) \ 192.168.0.0/255.255.0.0 \ (rw,fsid=0,hide,insecure,no_subtree_check,sync,root_squash) /export/folder 192.168.10.0/255.255.255.0 \ (rw,nohide,insecure,no_subtree_check,sync,no_root_squash) \ 192.168.0.0/255.255.0.0 \ (rw,nohide,insecure,no_subtree_check,sync,root_squash)

We need to activate the nfs server and read the export file above.

@server> systemctl start nfs-server.service @server> exporfs /export 192.168.10.0/255.255.255.0 /export 192.168.0.0/255.255.0.0 /export/folder 192.168.10.0/255.255.255.0 /export/folder 192.168.0.0/255.255.0.0

We can go to mount folder on client. There, we make the folder folder and we mount it. The error we get, of course, is the one above:

@client > mount -vvv server:/export/folder /folder mount.nfs4: trying text-based options 'tcp,soft,intr,rsize=32768,wsize=32768, vers=4.1,addr=X.X.X.X,clientaddr=Y.Y.Y.Y' mount.nfs4: mount(2): No such file or directory mount.nfs4: mounting server:/export/folder failed, reason given by server: No such file or directory

So what are we doing wrong? Very simple, we are trying to mount /export/folder, instead of folder. This will work:

@client > mount -vvv server:/folder /folder

You can now add it to the /etc/fstab and reboot to check it’s back there after the reboot. Be aware that I have the client and the server on the 192.168.X.X network! See you…

The issue was that the directory appeared to have non-visible characters at the end of its name. Using a shell globbing pattern, Gullane*, the user was able to enter the directory, and then also to rename the directory with a more usable name:

mv Gullane* Gullane

The * part of the globbing pattern would match the blank/non-visible characters at the end of the name regardless of what they are.

Issues related to applications and software problems

Massa_Kenzo Posts: 5 Joined: 2016/05/19 11:47:37

Hi All,

Am new to SAN storage installation and linux itself I am trying to mount the SAN storage to a server but each time i keep failing and getting the below error after restart. May you please assist

Possibly non-existing device? fsck.ext4: No such file or directory while trying to open /dev/mapper/VolGroup-LogVol_var Possibly non-existent device?

*** An error occured during the file system check. *** Dropping you to a shell; the system will reboot *** warning -- SELinux is active *** Disabling security enforcement for system recovery *** Run 'setenforce 1' to reenable. Give root password for maitainance


aks Posts: 3073 Joined: 2014/09/20 11:22:14

by aks » 2016/05/19 16:09:45

/dev/mapper/VolGroup-LogVol_var

The volume group (possibly for the /var partition) is missing. You can check with vgs command (and pvs for the physical layer).

Oh the SAN side is the LUN still presented to the machine?




Have a lab Centos 7.1(kernel 3.10.0-693.21.1.el7.x86_64) installed in Virtualbox 5.2.18, host is Windows 10. This VMs was install months ago and recently I power it up and found an issue which I hope to understand and learn to resolve.

in the /root folder there are 2 text files, only one of them got this issue.;

  1. can't "cat", vi, 'more' or 'less' the file, error is => "dir: cannot access a: No such file or directory"
  2. can be copied, via 'cp', but the copied file also got this same issue. The copied file can be deleted.
  3. The command "file" and "stat" output look normal to me.

I created a new file called test2.txt, in the same folder and it didn't experience this issue. Below screenshot show both file using Stat. The file with issue is "test.txt"

Stat output screenshot

Guess it is hard link issue, I was testing that months ago. Please share is there step or guide to troubleshoot this issue. Thanks!