Solved

Linux Mount var folder problem

Posted on 2010-11-18
3
524 Views
Last Modified: 2012-05-10
I want to mount an external harddrive to var folder but whenever i mount it aftrer installing brand new linux cent os it looses all folders in it , how should i securely mount disk to var folder without loosing all content in var
0
Comment
Question by:3XLcom
3 Comments
 
LVL 7

Accepted Solution

by:
Hatrix76 earned 350 total points
ID: 34167759
You do not loose anything.

you have to understand what mounting means. You mount a filesystem to a directory, and the directory will become the new filesystem (in your case the external harddrive). All contents below the mount-directory (in your case var) will not be accessible until you unmount the harddrive.

Why in the first place do you want to mount something to /var?

normaly you mount something to /media/<something> or /mnt/<something> .... the logic of mounting something to /var eludes me in the moment.

If there is a real reason to mount to your /var please state your requirements for doing so.

best
Ray
0
 
LVL 23

Assisted Solution

by:savone
savone earned 150 total points
ID: 34167797
Hatrix76 explained why your stuff is not accessible when mounting external HD to var.

If you want to keep your external HD mounted to var and still have the stuff in var accessible, you will have to move all the stuff in var to your HD.

So mount your external HD to /mnt/exthd (or whatever floats your boat)

Then move everything in var to /mnt/exthd

then unmount /mnt/exthd and remount it at var like you want.

0
 

Author Closing Comment

by:3XLcom
ID: 34167893
i see :) i have a scsi disk 140 Gb but my web sites is more then 200Gb so i bought an external disk , plesk use var folder for store emails and vhosts and ....
ok i will try it :)
0

Featured Post

VMware Disaster Recovery and Data Protection

In this expert guide, you’ll learn about the components of a Modern Data Center. You will use cases for the value-added capabilities of Veeam®, including combining backup and replication for VMware disaster recovery and using replication for data center migration.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Why VNC doesn't work in Redhat? 11 42
linux ssh 4 58
nagios 1 22
how can I get powershell to show the history of commands used ? 10 45
I. Introduction There's an interesting discussion going on now in an Experts Exchange Group — Attachments with no extension (http://www.experts-exchange.com/discussions/210281/Attachments-with-no-extension.html). This reminded me of questions tha…
It’s 2016. Password authentication should be dead — or at least close to dying. But, unfortunately, it has not traversed Quagga stage yet. Using password authentication is like laundering hotel guest linens with a washboard — it’s Passé.
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…

911 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now