Skip to content

PHP Linux How To Upload Files Into Block Storage

PHP Linux How To Upload Files Into Block Storage

Sometimes, you may need to use a huge amount of additional storage, and so some providers provide something called object storage, block storage or something along that line. To store files or upload them into your object or block storage, there are 3 solutions. 1. Change Mount Point To do this, you basically need to modify your /etc/fstab file. Example Commands :
    1. modify /etc/fstab file : vi /etc/fstab You may have a line that looks like the one below
      /dev/sda1 /blockstorage ext4 defaults 00
      
      So you just have to modify the 2nd field which is the mount point/directory
    2. reload : mount -a note: you can use findmnt to check if your mount point has changed note: you may need to change the owner and group using chown
2. Use symlink command
ln -s  <somewhere in mount point> <somewhere in web directory>
ln -s /blockstorage /home/website.com/public_html/some_directory
Enjoyed the content ? Share it with your friends !
Published inWeb Server

Be First to Comment

Leave a Reply

Your email address will not be published.