permission-denied

PHP move_uploaded_file() FAILS without reason

时光怂恿深爱的人放手 提交于 2020-01-21 17:26:23
问题 I can't make php upload work. PHP 5.4.45 Centos 6.7. Apache 2.2.27. I have a HTML file: <form enctype="multipart/form-data" action="test2.php" method="POST"> Send this file: <input name="userfile" type="file" /> <input type="submit" value="Send File" name="submit"/> </form> And I have PHP file: <?php $uploaddir = '/home/michael/public_html/forum/files/'; $uploadfile = $uploaddir . basename($_FILES['userfile']['name']); echo '<pre>'; if (move_uploaded_file($_FILES['userfile']['tmp_name'],

PHP move_uploaded_file() FAILS without reason

喜你入骨 提交于 2020-01-21 17:26:05
问题 I can't make php upload work. PHP 5.4.45 Centos 6.7. Apache 2.2.27. I have a HTML file: <form enctype="multipart/form-data" action="test2.php" method="POST"> Send this file: <input name="userfile" type="file" /> <input type="submit" value="Send File" name="submit"/> </form> And I have PHP file: <?php $uploaddir = '/home/michael/public_html/forum/files/'; $uploadfile = $uploaddir . basename($_FILES['userfile']['name']); echo '<pre>'; if (move_uploaded_file($_FILES['userfile']['tmp_name'],

Installing python module IOError: [Errno 13] Permission denied:

帅比萌擦擦* 提交于 2020-01-14 05:06:36
问题 I tried to install the python library openpyxl using pip by typing into the terminal: pip install openpyxl But it was not executed properly. It threw an exception: Successfully built openpyxl jdcal et-xmlfile Installing collected packages: jdcal, et-xmlfile, openpyxl Exception: Traceback (most recent call last): File "/Library/Python/2.7/site-packages/pip/basecommand.py", line 215, in main status = self.run(options, args) File "/Library/Python/2.7/site-packages/pip/commands/install.py", line

How to solve Permission Denied when running Sublime Text 3 from the terminal?

倖福魔咒の 提交于 2020-01-12 17:36:37
问题 The system is a Mac OS X El Capitan running Sublime Text 3. I was perfectly able to run ST3 from the terminal, using the symbolic link by typing "subl". I have no idea what could have possibly changed. Now everytime I try to start subl from the terminal in any given directory (by running "subl .") I get a "Permission Denied" window every 5 seconds. [Sublime opens the specified directory, whichever it is, and then everytime I switch back to ST3, the window pops up "Permission Denied"] The only

How to solve Permission Denied when running Sublime Text 3 from the terminal?

半世苍凉 提交于 2020-01-12 17:36:26
问题 The system is a Mac OS X El Capitan running Sublime Text 3. I was perfectly able to run ST3 from the terminal, using the symbolic link by typing "subl". I have no idea what could have possibly changed. Now everytime I try to start subl from the terminal in any given directory (by running "subl .") I get a "Permission Denied" window every 5 seconds. [Sublime opens the specified directory, whichever it is, and then everytime I switch back to ST3, the window pops up "Permission Denied"] The only

Unable to execute bash scripts even as root?

跟風遠走 提交于 2020-01-12 06:59:21
问题 I have a weird problem, I cant execute bash script even as basic as: #!/bin/bash echo "me" I am saving it as a test.sh and then do chmod 755 test.sh and once run ./test.sh getting: bash: ./test.sh: Permission denied any ideas ? cheers 回答1: That can happen if you have mounted the file system with the "noexec" option. You should remove it. 回答2: Script needs be executable. Use this: chmod +x <script-name> 回答3: Although not directly pertinent to this particular thread; if a file has come form a

What causes Permission denied errors when deleting files?

人走茶凉 提交于 2020-01-06 13:58:49
问题 I am trying to delete /var/www/main/user_resources/documents/NewFolder1/NewFolder1/noname3.php using PHP. As shown below, the file's owner and group is phped, it is group writable, and Michael belongs to the phped group. I am using Centos with Apache. [Michael@devserver NewFolder1]$ pwd /var/www/main/user_resources/documents/NewFolder1/NewFolder1 [Michael@devserver NewFolder1]$ ls -l total 4 -rwxrwxr-x. 1 phped phped 15 Jan 5 07:02 noname3.php [Michael@devserver NewFolder1]$ groups Michael

I am trying to format namenode in hdfs but says: permission denied

爱⌒轻易说出口 提交于 2020-01-06 01:35:59
问题 I am trying to format namenode . For this I have tried. hduser@Ubuntu:/usr/hadoop/hadoop-2.7.1$ bin/hdfs namenode -format It says: bin/hdfs: line 304: /root/software/jdk1.8.0_45/bin/java: Permission denied bin/hdfs: line 304: exec: /root/software/jdk1.8.0_45/bin/java: cannot execute: Permission denied 回答1: So, you have an odd install. It looks like you are trying to reference a JDK installation that is installed to /root (this is very unusual). You are getting permission denied because you

PHP execute shell command permission denied

夙愿已清 提交于 2020-01-05 07:59:30
问题 I installed an application (bagit) via homebrew and am trying to execute a shell command from my local Apache server (installed on OSX). My PHP looks like this: $cmd = 'bag create '.$targetFolder.' '.$sourceFolder.' --baginfotxt '.$bagInfoFile ." 2>&1"; $output = shell_exec($cmd); However, I am getting the following error message: /bin/bash: /usr/local/bin/bag: Permission denied How can I give Apache access to the bash command located in `/usr/local/bin? 回答1: Your apache install will need to

Jenkins not able to access java : localhost jenkins[807]: Starting Jenkins bash: /usr/bin/java: Permission denied

蓝咒 提交于 2020-01-05 07:02:08
问题 I have installed and configured jenkins on the centos 7.I have added valid java path i.e "/usr/bin/java" in the file /etc/init.d/jenkins . Below are the java path detils: lrwxrwxrwx. 1 root root 22 Dec 24 2015 java -> /etc/alternatives/java Now, on running "service jenkins start" command from root user , I am getting below error. ● jenkins.service - LSB: Jenkins Continuous Integration Server Loaded: loaded (/etc/rc.d/init.d/jenkins) Active: failed (Result: exit-code) since Wed 2016-07-13 18