Fedora :: Coverting Symlinks To Hardlinks

Aug 11, 2011

I'm wondering if there is a safe and reliable way of converting symlinks to directories to hardlinks? Basically I have a bunch of files in a directory tree under directory A, and I have in another directory B a set of symlinks to the original site. I would like all the files to end up in B and A to be empty. The links are all to directories, not to files, so the soft2hard script here won't work.

I don't have enough free diskspace to copy the files from A to B so I thought that converting the softlinks to hard links and then removing directory A would work? There are many directories, so would like to do it automatically if at all possible.

(In case anyone is intrigued, the issue is with my maildir directory. I used to use kmail, but with the move to kmail2 it became buggy and virtually unusable with large amounts of mail and I had to find another solution. I now use dovecot with gnus and mutt as MUA to access the maildirs. kmails maildirs are non-standard (!), so with the help of a script I found online, I created ~/dovecot and in it put symlinks to all the maldirs under ~/.kde/share/apps/kmail. The problem with this is if I accidentally start kmail it will try to access that directory and mess up all my tags, so I want to completely move all my mail from ~/.kde/share/apps/kmail to ~/dovecot, but without messing up all my tags etc.)

View 7 Replies


ADVERTISEMENT

Red Hat / Fedora :: Using Symlinks With SuExec

May 26, 2010

I just got a new server dedicated running php5 and SUExec. I understand the concept. INstead of running as "nobody", PHP scripts run as the user of that website. This also means I don't have to have some special directory where I set permissions to 775 or 770 with group=nobody etc just to upload files via PHP .. since PHP will upload files just as the user would using FTP. OK, great so far, and more security, I'm all for it.

View 1 Replies View Related

General :: How To Change Hardlinks To Softlinks

Mar 23, 2010

A missuse of the tool "fslint" created many (realy many) hardlinks in my /home folder. Now I am looking for a script, which converts all those hardlinks into softlinks. The difficult part will be to select a "major file". This is normally the file with the shortest path.

Using

Code:

find . -type f -printf "%n %p
"

I get all files including hard link count.

View 4 Replies View Related

Fedora :: How To Zip Symlinks (Real Files)

Mar 10, 2010

I have a directory full of symlinks. I want to zip them as if there were the real files. If I just zip them as usual, the resulting zip file does not contain the files at all! Is there any way to do this?

View 3 Replies View Related

Red Hat / Fedora :: Share Codebase Via Symlinks?

Mar 23, 2010

I'm hosting some sites on a dedicated server. All these sites make use of the same codebase (couple of directories with php and javascript files). Because I want to manage this codebase on only one location, I was trying to share it via symlinks. When looking at commandline, everything seemed to work fine. However, when browsing to the sites that use the codebase, problems occur. It seems as if php cannot find the files.

View 3 Replies View Related

General :: Difference Between Hardlinks And Soft Links?

Jul 1, 2011

whats the difference between hard links and soft links?

View 10 Replies View Related

Fedora Networking :: Samba Not Showing Symlinks Under Fedora 12

Mar 9, 2010

We recently upgraded our Samba server from Fedora 10 to Fedora 12. After the upgrade, when users connect to a Samba share from their Windows PCs, they can no longer see the symlinks in the share like they used to under Fedora 10.We are using the same smb.conf file as under Fedora 10, so I'm not sure what has changed.

View 2 Replies View Related

Fedora Servers :: Apache 403 Forbidden Error On Symlinks

Aug 12, 2011

the hard drive on my web server died so I replaced it and installed Fedora 15. I have been installing the OS on a small drive and then mounting other drive(s) for storage and did the same thing here. The problem is that I cannot get Apache to follow symlinks. Apache is partially working, it will serve my index.html page in the web page root directory and I made another directory called webtest and put some files in, and that worked fine. I made a symlink from the root directory to a folder on the mounted drive but when I try to access it, it gives me the old 403 Forbidden error. I also made a similar link in the webtest directory, I can view the other files in that directory but it does not show the link - also, trying to force it by typing the full path in the browser gives the same 403 error.

I have checked the permissions and SELinux types (using ls -Z) and they seem to be fine and I cannot find any .htaccess files. All the files on the mounted drive are owned by www:www but I also tried setting the user and group to www in httpd.conf and it still gave the same issue, so I changed them back to apache. I've been reading posts and sites on this for hours now and I'm still lost. I can post results of log files if they are of any use, I just wasn't sure what to post because it is somewhat working.

View 14 Replies View Related

Red Hat / Fedora :: Cannot Access Symlinks In Apache Root Directory

Nov 17, 2008

I have configured apache on my Centos 5.2 and it is working well. I want to have a sym link of my docs directory in /root/ in the apache root directory. I used ln -s command to create this sym link. But when I tried to access this I get the following error:

You don't have permission to access /docs on this server. Additionally, a 403 Forbidden error was encountered while trying to use an ErrorDocument to handle the request.

How can I access this directory in apache. i use apache 2.0.63.

View 1 Replies View Related

General :: Osx - Move A Bunch Of Hardlinked Files From A Box Onto OS X Mac And Preserve The Hardlinks?

Dec 8, 2010

I have an rsnapshot backup that I need to move off of a corrupt Linux file system. I need to preserve the internal hardlinks. I've tried rsync -H and using a newer rsync and neither preserve the hardlinks on OS X.

I tried to get rsync -H working and I've isolated it to the file system mounted. I can preserve hard links copying locally (HFS to HFS) but it doesn't preserve when I try to rsync off of a SMB file system mount or AFP file system mount. Is there some mount option solution to getting OS X rsync to obey -H?

View 2 Replies View Related

Software :: Symlinks Not Updating

Oct 18, 2010

Not sure what else to call it. My softlinks are not updating to reflect the parent/linked folder-files.

Code:
ln -s /folder/* /home/user/Music
This produces what I want. However, if I make any changes to /folder/, I dont see a reflected change in the links at /home/usr/Music.

A added plus would be to be able to use folder/file thumbnails from the source directory on the symlinks. Are sym links just shortcuts or are they real links to the directory (dynamic).

View 2 Replies View Related

OpenSUSE Network :: Samba Not Following Symlinks

Aug 19, 2011

When I access my OpenSUSE box's samba shares from another PC I am able to browse them, but am not able to follow symlinks.I've had the problem before on Ubuntu and fixed it by adding the following lines to my /etc/samba/smb.conf

unix extensions = No
wide links = Yes
follow symlinks = Yes

I've added them into my OpenSUSE smb.conf (below) but still no joy.

View 1 Replies View Related

General :: No Symlinks Allowed In Smb Share?

Feb 8, 2010

I have the following share setup on my Ubuntu machine

# From /etc/fstab
//192.168.1.13/media /home/USER/SHARE/media cifs username=USERNAME,password=PASSWORD,_netdev,uid=USER,gid=users 0 0

[code]....

View 1 Replies View Related

Ubuntu :: How To Find And Clean Old Symlinks?

Mar 2, 2010

I recently tried the package "pysdm" to mount a data partition but didn't care for the way it handled things so I opted for editing fstab which I'm much more satisfied with.I did then purge pysdem and it's config files but something lingered, finally I got things working by using a UUID designation in fstab but I know there's an old symlink to a /dev/sdb7 that has since been deleted and later recreated with a new UUID.

I have "googled" enough to find that the package "fslint" should be able to handle this but since one gui got me in trouble I'm reluctant to use another, I'd prefer just being able to find where symlinks live and ripping them out by the short hairs

View 2 Replies View Related

Ubuntu :: Symlinks Across Mounted Drives?

Mar 29, 2010

What is the syntax if you want to create a symlink to a resource on a mounted drive? am I missing something?

View 2 Replies View Related

Ubuntu :: Upload Files Through Symlinks?

Sep 9, 2010

Not sure this is appropriate here but wondering if one has advantage over other in terms of sharability?

Also is it possible to upload files through symlinks? ie put a simlink to a tar ball located elsewhere on filesystem than ubuntu one/dropbox folder.

View 6 Replies View Related

Ubuntu :: Symlinks Into Encrypted Directory?

Dec 17, 2010

shed some light on what the behavior would be if I symlinked a non-encrypted directory (lets call it /media/sdcard/foo) into an encrypted home directory (lets say home/documents/sdcard-docs)Would files written to that symlinked directory be encryptedgarbled, or would they be normal? would files that were attempted to be read be interpreted as encrypted, or would they be read properly?

View 1 Replies View Related

Ubuntu :: Deleting Wine Symlinks?

Apr 12, 2011

I did a "backup" of my .wine folder by copying it to my network attached storage drive. Now, that folder thinks it has about 200gb of data! Specifically, it's the .wine/dosdevices folder. I didn't grasp that Wine had created some kind of hard links to my ~ folder on my Ubuntu box. Since that folder is clearly recursively linking to all my files, I'm afraid to just delete it. I did delete one file within it as a test and, sure enough, the original file back on my Ubuntu box disappeared!how can I delete the .wine "backup" folder I created on my NAS without deleting all the original files?

View 5 Replies View Related

General :: Can Grep Exclude Symlinks?

Oct 15, 2010

I tried to run one grep that excludes symlinks and pipe it into a second that searches for my pattern but I continue to get the recursive directory loop error. As a result (I think) my grep is incomplete as the search just loops between directories symlinked together.

View 7 Replies View Related

Software :: Rsync Behavior With Symlinks

Feb 24, 2011

I am trying to do an rsync that includes a symlink in a folder. I only want the symlink to change on the destination if the mod time of the symlink on the source is newer. The behavior i am seeing is that the symlink on the destination is always updated to match the source regardless of the mod time.

View 2 Replies View Related

Debian :: Certain Programs Like Apt Refuse To Recognize Symlinks

Jul 6, 2015

This system was first installed on a 120Gb dual booted hard drive with Debian split with XP. It grew into a development system spanning 3 drives and 360Gb.

The addition drives were NOT mounted under the standard unix conventions, such as sdb being /usr and sdc being /home. They are mounted as /drive1, /drive2. All ext4 (except for the /dev/sda1 XP partition).

For example opt is symlinked to /drive1/opt

Firefox is at /drive1/opt/firefox.

So far so good, and with 20,000 packages installed, the system does work. With however, some caveats.

Certain programs like apt, refuse to recognize symlinks. I cannot move its /archives to the other drives. Some other stuff seem equally recalcitrant. Especially stuff from the lower init levels (that is understandable as they are running before the mounting process).

But others are unexpectedly recalcitrant.

Is there any way to *force* systemwide respect for symlinks?

Reducing size of XP is a non-starter here...

View 7 Replies View Related

OpenSUSE Install :: Repo With Only (symlinks To) New Versions?

Aug 13, 2010

that's it! I got OpenSuse 11.2 and the size of the Repo has exceeded the 4 GB limit. This means that the mirror doesn't fit on my USB-stick anymore, nor would it fit on aDVD-RAM/RW (thus I can't distribute the updates anymore). Yes, there are bigger USB-sticks and BR-RWs, but in the end it is pure insanity!

View 1 Replies View Related

General :: File Permissions Apply To Symlinks?

Jun 27, 2011

Let's say you have this structure:

+ directory
-- file1
-- file2
-- file3 -> /tmp/file3

file3 is a link to another file3 somewhere else on the system.

Now let's say I chmod 777 the directory and all contents inside it. Does my file3 in /tmp receive those permissions? Also, let's say we have the same situation but reversed.

/tmp/file3 -> /directory/file3

If I apply the permissions on the file being linked to, how does that effect the link?

View 2 Replies View Related

Ubuntu :: CIFS Share No Longer Following Symlinks

Jun 6, 2010

I just made the upgrade to 10.04 over the weekend, and everything seems to be working fine, minus one nagging detail.I have a Mythbuntu setup - a frontend and a backend. In addition to recording television, I have a folder setup on my backend where I can dump movie files to watch on the frontend. The folder is shared in the /etc/fstab via a CIFS share. Within that folder is a symlink to where my torrent folder is located. The issues seems to be how my frontend handles symlinks within the shared folders. If I run "ls -la" in my base CIFS share folder, it lists the symlink folder and says it's owned by root, but if I try and change to that directory - either using "ls" or "cd" - it says Permission Denied. On the backend, I changed ownership of the symlink to the username the CIFS is using to login, but that had no effect. I'm not familiar with how to do any sort of configuration on CIFS, if that's where I'd even need to start.

View 2 Replies View Related

General :: Linux And Windows Symlinks Interchangeability

Apr 10, 2010

This question is about windows 7. I want the "C:program Files" folder to be a symlink to a directory on another partition. I can't do this from within windows because it locked the Program Files Folder. Will a linux live CD do the trick?

View 1 Replies View Related

Security :: Group Permissions Or Symlinks Best Practice

Aug 21, 2009

I was about to post a new thread and saw that there are several answers out here already and I have done the new group permission one on my server -- actually on my test server I just added "my user" to the group "root" to gain rw access to /var/www/htdocs/.Someone suggested that the proper way might be to do symlinks to the directory in a real production environment and I wanted to find out if that is the *best* way to go or whether to actually make a group "www_admin" (pick your favorite flavor of this) and add my users to that group?

I guess I am looking for the "best practice" in a real corporate production environment that is most secure.

View 3 Replies View Related

Software :: Use Symlinks In Annon Ftp Dir And Proftp - Error 550

Jan 9, 2010

I wanted to use symlinks, in my annon ftp dir. I was running vsftp, but everyone says it can't be done. So I have changed to proftpd. I link to the annon ftp server on my website. I get the dir listing, with symlinks, but try to follow them I get error 550, it don't exist. I have read [URL], but after following the advice here. I get the same error. I have not tried the mount bind option, as I want symlinks or hard links either will do.

View 3 Replies View Related

General :: Resolving Symlinks Mounted Via Samba On Windows?

Feb 11, 2010

I have a samba mount in Windows, mounted from a local Linux devbox. The projects on this mount contain a lot of symlinked directories. They all work fine and look like normal directories to Windows. What I'd like to do is figure out for a given file what its real UNIX path is.The context is: in my editor I have a script that runs the Perforce open command, to which I pass the file location.p4.exe edit FILE_LOCATION

However, perforce will not understand this FILE_LOCATION, if on the Linux side part of the path is a symlink. It needs to know the real path.What I need is something along the lines of the Linux readlink command, which resolves symlinks in paths.

View 1 Replies View Related

General :: Moving Symlinks Into A Folder Based On Id3 Tags?

Apr 3, 2010

I'm trying to get my music folder into something sensible. Right now, I have all my music stored in /home/foo so I have all of the albums soft linked to ~/music. I want the structure to be ~/music/<artist>/<album> I've got all of the symlinks into ~/music right now so I just need to get the symlinks into the proper structure. I'm trying to do this by delving into the symlinked album, getting the artist name with id3info. I can do this, but I can't seem to get it to work correctly.

for i in $( find -L $i -name "*.mp3" -printf "%h
")
do
echo "$i" #testing purposes

[code]....

I'm trying to mv The Trance Mix 3 Wanderlust - DJ Exortius [TRANCE DEEP VOCAL TECH]@ into the real directory DJ Exortius. DJ Exortius already exists, so it's just a matter of moving it into the correct directory that's based on the id3 tag of the mp3 inside.

PS: I've tried easytag, but when I restructure the album, it moves it from /home/foo which is not what I want.

View 2 Replies View Related

General :: Copy Symlinks To Target As Normal Folders?

Nov 30, 2010

i have a folder with symlinks:

marek@marek$ ls -al /usr/share/solr/
razem 36
drwxr-xr-x 5 root root 4096 2010-11-30 08:25 .

[code]....

i want to copy it to ~/solrTest but i want to copy files from symlink as well when i try to cp -r /usr/share/solr/ ~/solrTest i will have symlink here:

marek@marek$ ls -al ~/solrTest
razem 36
drwxr-xr-x 5 root root 4096 2010-11-30 08:25 .
drwxr-xr-x 358 root root 12288 2010-11-26 12:25 ..

[code]....

View 4 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved