Smart SVN Folder permission - smartsvn

I am using smartsvn on windows and i have wordpress site configured with that, but i have 2 issues,
When i make changes on my local machine and commit it reflects after 1 day, i don't know why 1 day delay,
Also recently i am having issue with upload folder , due to folder pemission i can not upload image and i don't know how to change folder permission
define('CHMOD', '777');
chmod -v 746 DIR
chmod -v 747 DIR
chmod -v 756 DIR
chmod -v 757 DIR
chmod -v 764 DIR
chmod -v 765 DIR
chmod -v 766 DIR
chmod -v 767 DIR

Related

How to rewrite `-r-------- 1 apache apache a.txt`?

There's a file -r-------- 1 apache apache a.txt.
Now,I open GNOME Terminal 3.14.3. Even su root cannot rewrite this file.
How can I solve this problem?
Try the following commands:
sudo chmod 777 a.txt
sudo cp a.txt /home/your-username/a.txt
Now make your changes and run the following commands:
sudo chmod 777 a.txt
sudo cat /home/your-username/a.txt > a.txt
sudo chmod 400 a.txt
Note: Make sure that you replace /home/your-username with your home folder and you set the working directory to the directory where the file is in.

Magento httpd permissions issues

I am trying to install magento2 on a CentOS server. I am continuously getting permissions issue, the magento diretory is owned by apache and I set permissions to 777 (i know it is bad but just to test) but I still get permissions denied on file write. the path to magento dir is /var/www/html. I set permissions to /var/www/ and all sub-folders to 777 and file owner to apache still same.
also
egrep -i '^user|^group' /etc/httpd/conf/httpd.conf (returns)
User apache
Group apache
any suggestions or ideas, please?
Kind Regards
Sajid
Try following steps
sudo /usr/sbin/groupadd wwwrun
sudo usermod -g wwwrun test
cd /var/www/html/magento2 && sudo find var vendor pub/static pub/media app/etc -type f -exec chmod g+w {} \; && sudo find var vendor pub/static pub/media app/etc -type d -exec chmod g+ws {} \; && sudo chown -R apache:apache . && sudo chmod u+x bin/magento
where test is the current logged-in user and then restart the http server.

Magento emails not working error log 403

All emails in my Magento 1.9.2.4 shop : invoice , new registration , contact us.... not work. I recive error log 403.
I haven't make any changes on the site. Can the reason be in the cPanel?
You can run the following commands:
find ./ -type f | xargs chmod 644
find ./ -type d | xargs chmod 755
chmod -Rf 777 var
chmod -Rf 777 media

Count number of files in directory then scp transfer a certain range such as 21404-42806

I found the number of files in /dev/shm/split/1/ to be 42806 using:
/bin/ls -lU /dev/shm/split/1/ | wc -l
What I can't seem to find anywhere online is how to select a certain range, say from 21404-42806, and use scp to securely copy those files. Then, for management purposes, I would like to move the files I copied to another folder, say /dev/shm/split/2/.
How do I do that using CentOS?
I tried:
sudo chmod 400 ~/emails/name.pem ; ls -1 /dev/shm/split/1/ | sed -n '21443,42806p' | xargs -i scp -i ~/emails/name.pem {} root#ipaddress:/dev/shm/split/2/
This produced:
no such file or directory
errors on all of the files...
ls itself lists files relative to the directory you give. This means your ls prints the filenames in the directory, but later on, scp doesn't have the path to them. You can fix this two ways:
Give the path to scp:
ls -1 /dev/shm/split/1/ | sed -n '21443,42806p' | xargs -i \
scp -i ~/emails/name.pem /dev/shm/split/1/{} root#ipaddress:/dev/shm/split/2/
Change to that directory and it will work:
cd /dev/shm/split/1/; ls -1 | sed -n '21443,42806p' | xargs -i \
scp -i ~/emails/name.pem {} root#ipaddress:/dev/shm/split/2/

permission in var/www on ubuntu

I was able to access and view the files when i first set it. i then realize that my css sheet was not running so i check the source code in Firefox and realize that i didn't have permission to view this file. so i decided to run a permission on the entire www folder.
Now im getting a 403 error. i tried changing back the permission but still having the same problem. i tried
find /var/www/ -type d -exec chmod 755 {} \;
find /var/www/ -type f -exec chmod 644 {} \;
these didn't work, please help
sudo chmod 0777 -R /var/www
-R is recursive, I assume that your web files are located in /var/www.