External hard drive formatted with wrong fs for nfs

Hi there another callout for help!

I am trying to mount on an old SGI computer an external storage drive on a Linux PC. I think the problem may be to do with the storage drive user permissions. I've tried to create mount points on the linux pc and on the SGI.
When I enter showmount -e on the SGI the exports appear, but then trying to mount them, the shell does not return.
In the case of mounting the storage on the pc desktop I have a message saying wrong fs type , see screenshots for the whole ominous response;)


It seems the /dev/ mount fails because the OS cannot detect the filesystem type on it.
Give an explicit type as an option, say ntfs:

mount -t ntfs /dev/sdc /home/karhu/store2

If there is a matching entry in /etc/fstab, then the filesystem type and perhaps further options are picked from it, and you can do the simple mount without options.

Also (before the mount) ensure that the mount point directory is present:

mkdir -p /home/karhu/store2

After a successful /dev mount you must redo the NFS export:

exportfs -v /home/karhu/store2

The missing options are picked from a matching entry in /etc/exports.

A mount error like "permission denied" is a response from the NFS server; the communication has worked.
A "hanging" mount command (will time out after a long time) is a communication problem, e.g. a network problem.
Most NFS clients do some retries; if there is a "permission denied" after a long time, then there was a successful communication after some retries - previous attempts failed.

Thank you so much for the code and advice.

With it, I could mount the storage drive in a folder on the homepage of the linux pc server.

However there was still a problem exporting, saying nfs does not support the fs (which was exfat). And I couldn't mount it on the client with nfs permission denied.

I'm going to reformat the hard drive, which is 10TB sata as gpt using the linux disk utility. Then I'll try to reinstall the LINUX OS on this drive. Not sure if this is a good idea but sadly I'm not having much luck resolving this problem!


Ah yes, exfat (and likely ntfs) cannot be NFS-exported!

Yes, if possible "reformat" it to a Unix/Posix file system, e.g. ext4 is very reliable.
Attention, the "format" (that is a "mkfs" in Linux) overwrites the data on it.

Ah, it all makes sense now, phew!

USorry just one other thing,..

I'm away from the workstation now, but in reformatting with LINUX I used the GUI disk utility where there were 2 options MBR-DOS or GPT. If the GPT isn't a a Unix/Posix file system, could I reformat from the command line prompt?

No that's the partition label format.
MBR is older and cannot handle >2 TB disks.
You do not need to recreate it. But perhaps you want to alter the existing partitions.

Each partition that can be mounted must have a filesystem. If you do not alter the existing partitions, you only create a ext4 filesystem that overwrites the exfat filesystem.

In this topic and your previous topic you had a local filesystem that you mounted locally (on the Linux server) - success

You then created a NFS share of that filesystem on Linux server - success

You then ran 'showmount' on the SGI client and could see that remote NFS share - success

You then had difficulty in NFS mounting that share onto a SGI local mountpoint. That was the problem we are trying to fix.

For clarity please be aware of the difference between a local mount of a filesystem

# mount /dev/<local filesystem device node>  <local mountpoint>

and mounting a remote NFS share onto a local mountpoint

# mount <path to remote NFS share> <local mountpoint>

They are completely different mounts.

Many thanks for the clarification, I had little confidence that mounting the drive locally would work, for the reason to then export the drive from this local mount point.

It now seems that the problem is the formatting of the additional drive. I have used the GUI linux disk utiltiy to erase everything on the disk, using GPT, and it has taken a long time.

I need to format it with ext4. I wonder will this happen autiomatically, and if it does, will the drive automatically mount in the linux server, If it does not, must I still first mount it in the linux pc in order to export it to the SGI?

Sorry for all the questions!

No, partitioning provides the space for a file system but not the file system.
If your "GUI linux disk utiltiy" did not ask for a file system then its creation is not integrated.
On the command line, there are separate steps:

  • create the desired file system with mkfs
  • edit /etc/fstab to have it mounted at the next system boot
  • mount it now (the best method is to only provide half of the information, then the missing part is fetched from the fstab entry. This verifies that the entry works)
  • edit /etc/exports to have it exported at the next system boot
  • exportfs it now (the best method is to only provide half of the information, then the missing part is fetched from the exports entry. This verifies that the entry works)

And then mount it on the SGI (you can make an entry in its /etc/fstab to have it mounted at the next system boot)

Be careful with /etc/fstab! A bad entry will boot the box into maintenance mode in order to get the fstab corrected on the command line!