Ubuntu :: Using /etc/crontab To Force Chown And Chmod In Specific Directory?
Feb 9, 2011
I need to actively make sure some files, in a specific directory, are chmod 750 and owned by transmission:media-daemons. Other users will save to this directory, with other permissions and UID/GID but I must make sureto reinforce this default.
So I have this on my /etc/crontab:
Code:
# /etc/crontab: system-wide crontab
# Unlike any other crontab you don't have to run the `crontab'
# command to install the new version when you edit this file
# and files in /etc/cron.d. These files also have username fields,
# that none of the other crontabs do.
[Code]....
View 1 Replies
ADVERTISEMENT
May 30, 2011
Need to recurse a subdir tree, to apply chmod and chown and ls -al .
chmod -R xxx yyy does not function properly; -R is nonfunctional.
chown -R xxx yyy functions OK.
Is there a script which will follow a subdir tree and open each subdir ? glene77is
View 9 Replies
View Related
Aug 30, 2011
I'm trying to make a particular file accessible on my computer ( /dev/uinput ) without having to use sudo or su - I've set up a wiimote to act as a remote for my media player, and it requires access to that file. When I use chmod, chgrp or chown to change the file's settings, it enables access to the file - however, when I reboot my PC, the settings get reset, and I have to change the access rights when I first use it again. I've tried using the following commands to make the changes (substituting my username/groupname as user and group below), as root:
[Code]....
View 2 Replies
View Related
Mar 29, 2010
I occasionally get into areas in Linux where I get my own ignorance demonstrated....System is a core quad running OpenSuse 11.2 64 bit on a LAN at home. I added a 750 GB SATA drive with the idea of putting all media on the drive i.e.music primarily plus a few movies and making the data sharable by anyone across the LAN i.e. the computer in the living room with an audio line to the stereo. My room mate is strictly a Windoze user so I figured if she wanted stuff on her machine as well then format the new drive with NTFS which I did using GPartd. I then set the drive to mount as /storage under root.
I loaded the music library &c and although I can play music from my user account on this machine I can not add music or videos or anything else except as root. I dont want to have to change to /root to do this. I attempted a chmod tonight as su from a terminal then in the root GUI using dolphin and resetting the permissions under properties and nothing changes. The drive appears in the filesystem as /storage with ownership as root. The permissions are
drwxr-xr-x 1 root users 4096 2010-03-27 22:55 storage
trying to chmod as root has no effect at all. I would like to be able to add content from any machine on the LAN plus be able to play a movie or video as well as music (I assume this would need the execute permission) but chmod -R 777 storage has no effect. Neither does cd'ing to the directory and trying to change ownership or permissions on the individual files or directories on the drive.Command line as su or as root from that gui, no difference. I do a
chmod g+w,o+rw storage
and the command appears to execute.However I ls -l and find the permissions unchanged. I obviously have or am doing something wrong, possibly in the way I set the drive up in the first place.
View 8 Replies
View Related
Dec 8, 2010
In Linux, how do i prevent users from executing chown, chgrp or chmod?
View 2 Replies
View Related
Apr 27, 2010
I am desperately trying to recover two folders from a Freecom FSG 3 NAS. As far as I am aware it is running Linux 2.6 based on Snapgear. After working through the hardwares' recovery procedure a number of times, the state of the device appears to get worse and worse. So I have attempted to rescue the files by using a program called Putty to access the device over SSH.When I access the device using Putty I login as admin. The folders I need to recover are located in the home folder. Listing the contents of the directory I get...
/home $ ls -la
ls: ./.twonkymedia: Permission denied
ls: ./Sarah: Permission denied
[code]....
View 1 Replies
View Related
Jul 3, 2010
As root, I use crontab to run mirrordir to backup directories. Everything gets copied over properly, but owner information isn't preserved and root is the owner of all the backed up files. I can deal with that, but crontab reports tons and tons of chown/chgrp errors for mirrordir every time I do back ups--which is every day--and the multiple emails to root of thousands of chown/chgrp errors is very annoying. The error is "Operation not permitted," but that doesn't make sense to me because the job runs as root (right?) and clearly the job is permitted to create the backup files, so why would it fail to chown and chgrp?
I've had the exact same setup on another server for years, and crontab has always run mirrordir without error. Any suggestions how to clear the errors on my new server?
View 14 Replies
View Related
Jun 15, 2011
I am running to a weird issue: for some reason when I try to run a crontab script which has these two operations:
#!/bin/sh
DATE=`date +%F`
but when I reduce this script to the first sql backup only and I use another cron job to put this dump file to the folder it goes through...weird isn't it?so 1+2 in 1 cronjob don't work but 1 in 1 cronjob and 2 in another cronjob it works perfect. any thoughts?
View 3 Replies
View Related
Mar 17, 2011
We have configured a script to be run at specific time using crontab.
Code:
# crontab -l
as per the crontab entry script should run every day 11.15 a.m
Every time when the script is executed i get a mail but when i run it using crontab it doesn't send any mail.
However when i execute it manually i get the mails.
Even the execution is getting logged in cron log.
Code:
View 2 Replies
View Related
Jun 25, 2011
I run a bunch of CentOS 5.6 servers, where we continuously deploy our software. Our software comes in self-made rpm packages from a network-local yum repository. As bugs happen in software development, I sometimes want to downgrade to the previous release, so force the installation of a specific version of the package.I tried the allow-downgrade plugin, but so far no luck. Neither yum update nor yum install seem to work with allow-downgrade. (It does not seem to do anything?). Does anyone have a working example for yum --allow-downgrade?
This is what I tried:
1) Show current yum version
[root]# yum --version
[code]....
View 5 Replies
View Related
Mar 4, 2010
I've got a machine running 9.10 with two network interfaces, one being motherboard based (atl1) and the other in a PCI slot (e100). By default at boot the interfaces come up in the wrong order. I'd prefer to have the e100 come up as eth0 instead of eth1. And then have the atl1 come up on eth1 instead of eth0. Both interfaces use static addresses and IP4 routing should be active across them. Where do I configure things to force the specific settings?
View 2 Replies
View Related
Feb 7, 2011
I just upgraded my storage server to maverick and it seems the 2.6.35-25 kernel doestn like the hardware im using
since im pretty sure its a hardware related problem and the previous kernel hastn the issue im currently booting this old kernel everytime i need the server by hand (using Shift during boot for the grub menu to appear)
well, it narrows down to the following question:
how can i exclude a specific grub entry - in my case the current kernel 2.6.35-25 - so only previous kernels OR future kernels from the next updates will have a chance to boot?
View 4 Replies
View Related
Dec 18, 2010
The software I just bought (Lightroom 2.1) contains instructions to get my serial. I downloaded the sofware on my desktop and installed it. In the terminal, I wrote "chmod +x keagan", pressed enter and wrote "./keagan" and I get this message: No such file or directory. what I am doing wrong? I am working on Mac OS 10.4.
View 6 Replies
View Related
Jul 15, 2010
I decided I was going to compile XChat from source today for "fun." What I ended up doing was spending a few hours getting it to compile, then find out everything didn't work the way I thought it did. I was under the impression that after I ran "sudo make install" I was "upgrading", when in reality I'm just installing a seperate version alongside the old one. Apparently I have to keep the old version so every program that was compiled with it will continue to work, so how do I:
1) Force a program to use a specific version of GTK when compiling.
2) Find where my version of GTK installed to.
I've asked some people and I've just been told to "learn LD_PRELOAD". I've googled and can't figure how I could even apply that to my current problem
View 3 Replies
View Related
Jul 11, 2011
concerning controlling the windows in virtual desktop.
a) Say to a application to be launched to virtual desktop 2 for example.
b) How can you ask from a virtual application to be only visible at one virtual desktop. For example I work on virtual desktop 6 and I want to start skype that should be on virtual desktop 2. Right now If I launch the app on virtual desktop 6 it will appear on the same one. Would it be possible to ask for an applicaiton to be launched on an other virtual desktop. If yew how?
View 7 Replies
View Related
Aug 12, 2010
I'm hoping some of the Linux network experts can help me with this problem.
Situation: I have a technology which is a WebLogic JEE application that communicates to an Oracle database. Everything is installed in a single Linux virtual machine running in VirtualBox. Traffic from the JEE application goes via JDBC over TCP to the local running database. What I want to do is test a new database firewall server that wants all traffic destined for the database to flow via another virtual machine running the DB Firewall software.So therefore want I need to do is have DB traffic forced out over one interface only to return on another interface on the same VM listening on a different address.
JEE application running in WebLogic bound to 192.168.111.12 (eth1 a VirtualBox hostonly interface). Makes a request for 10.0.111.12 (eth2 a VirtualBox internal interface) which the database is listening on. Because both IPs are on local interfaces, Linux is going to handle the traffic and not route the 10.x traffic via the 192.x interface.I also have running the database firewall server which has a bridge (br0) between the HostOnly network and the Internal network.Both systems are running Oracle Enterprise Linux R5U4, which is basically the same as RedHat.What I want to do is have the request for 10.0.111.12 forced out via 192.168.111.12, bridged over the br0 connection and back into 10.0.111.12 and to the database. My networking knowledge is pretty good, but i'm stuck right now on the right way to do this. I'm pretty sure it is possible, I just need clear advice.
Reason for setup: Ideally I would build the system with the database on a separate machine so that I can easily route the traffic. Unfortunately we have many VirtualBox based demonstration systems with both the application and database installed on the same VM and therefore the amount of work to migrate these two dual VMs is going to be significant, also many of these VMs are demonstrated from laptops which have limited resources and creating a new database VM reduces overall performance. If I can create a way to force the traffic in this manner off and back onto the same VM via the other VM bridge, it would be fantastic.
View 7 Replies
View Related
Apr 27, 2010
I am using Linux 64 bit Redhat Linux. I am trying to setup simple crontab as follow...1. Edited crontab file using crontab -e2. Listed the file once to verify it using crontab -l. This will display as.. 18 5 * * 2-3 ksh $HOME/testScript.sh > $HOME/testscript.out3. Logged in a root and restarted cron deamon using "/etc/init.d/crond restart"As per my understanding now my testScript should start running at 5:18 am Thuesday
View 3 Replies
View Related
Oct 22, 2010
here is the most importent part of the file setup.shhere link to pastebin:http://pastebin.com/mwQ1UArHand here the part:
cd
chmod 777 ../bin/panel
cd ../bin/panel
[code]....
View 2 Replies
View Related
Mar 31, 2010
I have created directories in root. I am looking for the chmod command to allow all users read and write permissions to a specific directory. I have done chmod 775 for a file but I need this for a directory. This includes permissions on all files and sub directories.
View 3 Replies
View Related
Aug 2, 2010
I have an external USB hard drive (sdb1) mounted at /media/Iomega HDD. When I try to do a chmod to a directory on this drive, chmod doesn't give me an error, but it doesn't change the privs - even when I'm root. Why is this?
Code:
root@d-desktop:/media/Iomega HDD# ls -lart
total 2176732
drwx------ 1 dan dan 456 2010-08-01 16:24 Unison
root@d-desktop:/media/Iomega HDD# chmod -v a+rwx Unison
mode of 'Unison' changed to 0777 (rwxrwxrwx)
root@d-desktop:/media/Iomega HDD# ls -larth
total 2.1G
drwx------ 1 dan dan 456 2010-08-01 16:24 Unison
root@d-desktop:/media/Iomega HDD# /usr/lib/klibc/bin/fstype /dev/sdb1
FSTYPE=unknown
FSSIZE=0
root@d-desktop:/media/Iomega HDD
View 14 Replies
View Related
Jan 17, 2010
I set up a samba server on my Linux box for the purpose of allowing everyone - and I mean everyone - on my LAN network to be able to put files to one folder... The only issue seems to be not having write permissions to the target folder.
Question, re-stated: How do I set the permissions for an entire directory to not require anyone to have a login? I have tried many things, such as "chown -aR /data/public", but I still cannot seem to find the magic words.
View 2 Replies
View Related
Jul 9, 2011
I am not an expert when it comes to crontabs and linux but i can survive in its world :P I've modified a script i found on the net to do a simple crontab job. Basically its a backup script (backup_auto.sh) that in the end of it, it updates the crontab also.
Code:
i just put the crontab job of the script....
if [ $CRONJOB -eq 1 ]
then
#Check if user can use crontab
[Code]...
I know for a fact that it doesnt run it because this .sh upload remotely some files for backup, and if i dont run it manually then i dont see any backups on the remote server
View 3 Replies
View Related
Feb 10, 2011
when a script in /etc/cron.d directory will be executed?. I know that scripts in cron.daily will be executed daily [ set in /etc/crontab file]? Cant able to find this directory listed in /etc/crontab file?
View 2 Replies
View Related
Jul 17, 2010
I accidentally did a 'chmod +x foo' when i meant to do a 'chmod a+r foo'.
-rw-r--r-- 1 casper trad 53 Jul 17 22:41 filegore
-rw-r--r-- 1 casper trad 13 Jul 17 22:41 filelemme
-rw-r--r-- 1 casper trad 24 Jul 17 22:41 nix
[code]....
View 1 Replies
View Related
Jul 10, 2009
I've just discovered that crontab is creating a new file in the root directory every time it executes a cronjob, and it doesn't erase over the old file so there are thousands of files in the root directory, they have the same name as the script file (appended with a numeral) but are all blank.here is what one of the cronjob's looks like[URL]
View 10 Replies
View Related
Jun 23, 2011
is it possible disabling a crontab job without deleting the crontab description entry (by crontab -e)?I could also accept to change the entry itself. Now it's:0 0 * * 0-6 /home/me/cron/script.csh
View 4 Replies
View Related
Jan 1, 2010
I'm using VSFTP in my ubuntu server and I want FTP to show me only the /var/www directory and its files/sub-directories. How can I do this? This has to do with vsftp.conf?Also I've read is recommended to make a user only for FTP, thus limiting its access to the desired directory. How can I do such thing?
View 1 Replies
View Related
Jun 13, 2010
How can I assign a directory to a specific partition (another hard drive)?How would someone move / home/ username/music to another drive or partition? But do so in a way that it no longer writes MP3's (or FLAC) files in the original directory of the root drive?
View 9 Replies
View Related
Apr 6, 2011
Using apt-get can I install java and tomcat into specific directories, instead of the default way apt would do it?
View 1 Replies
View Related
Jul 27, 2010
I am trying to download site using wget :$sudo wget -r -Nc -mk [URL] but it is downloading the contents of all directories and subdirectories under the domain :[URL] (ignoring the 'codejam' directory) so it is downloading from links like : [URL]... i want to restrict the download so that wget command should download only the things under 'codejam' directory
View 9 Replies
View Related