Mount is giving me trouble

Bit of a dumb linux question, I can’t see to mount my harddrive to a location outside of the /mnt directory:

Running

$ sudo mount /dev/sda1 /var/www/drive1/

Places nothing in the /var/www/drive1 directory.

/var/www/drive1 $ ls


Running lsblk shows the drive is mounted, but nothing can be found in that folder:

$ lsblk

NAME        MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sda           8:0    0 298.1G  0 disk
└─sda1        8:1    0 298.1G  0 part /var/www/drive1
mmcblk0     179:0    0  29.8G  0 disk
├─mmcblk0p1 179:1    0   2.4G  0 part
├─mmcblk0p2 179:2    0     1K  0 part
├─mmcblk0p5 179:5    0    32M  0 part
├─mmcblk0p6 179:6    0   256M  0 part /boot
└─mmcblk0p7 179:7    0  27.2G  0 part /

Am I missing something here? This works fine for the /mnt directory.

I don’t think that glitch even supports drive mounting.

This isn’t on Glitch, this is on my own machine.

3 Likes

Yeah, keywords:

  • my harddrive: Hard drives are physical
  • sudo mount: Sudo isn’t supported on Glitch

i think there’s something wrong with your computer?is it running any other software and/or programming languages?If not it either needs an update or restart

And if that doesn’t work i recommend maybe getting a new laptop/computer

Err, this is a question about linux and doesn’t have anything to do with the quality of my computer.

i understand that,but i’m also saying if it isn’t even running something similar to mount then either your Linux(i think) doesn’t support it anymore

I’ve been reading this thread and this has nothing to do with the OS version. OP, has mount worked in folders other than /var/?

Can you show what stat . in the mounted dir outputs under ‘Device’ and what ls -l /dev/sda1 outputs for device major and minor numbers? They should match up, modulo any hex/decimal conversions.

edit: or stat /dev/sda1 in the ‘Device type’ field. just realized that this has it conveniently already in hex

2 Likes

Odd, it seemed to work. All good now, thanks. No idea what went wrong, I viewed the directory as superuser and it appeared, then viewed as non super user and its still there. A tech issue I probably can’t explain.