nginx Permission denied) while reading upstream

2018/01/05 13:49:47 [crit] 31363#0: *68 open() "/app/nginx/nginx/proxy_temp/2/00/0000000002" failed (13: Permission denied) while reading upstream, client: 10.133.125.11, server: myjr.atguat.com.cn, request: "GET /bocopackage2/downloadPdfProduct.dhtml HTTP/1.1", upstream: "http://10.112.179.33:30123/bocopackage2/downloadPdfProduct.dhtml", host: "myjr.atguat.com.cn:30123", referrer: "https://myjr.atguat.com.cn:30123/bocopackage/inits.dhtml"



ps -ef |grep nginx

发现 master进程 用户是root work进程是Jenkins
修改配置文件vim nginx.conf
修改user nginx为当前系统用户,如:user nginx



其他
sudo chmod 777 /app/nginx/nginx/proxy_temp/ -R 修改文件夹及其子文件

sudo chown -R nginx:nginx /app/nginx/nginx/proxy_temp/ 修改用户和组为nginx

求助IOException (Permission denied)

07-24

如题,我先把报错原因粘贴过来rnrn07-24 03:25:07.898: ERROR/D.E. FILE NOT FOUND(1360): /sdcard/2499_com.mobi.filemanager.activity_142051.apk (Permission denied)rn07-24 03:25:07.908: ERROR/D.E. IO(1360): /sdcard/2499_com.mobi.filemanager.activity_142051.apk (Permission denied)rn07-24 03:25:07.908: ERROR/D.E. IO(1360): java.io.IOException: /sdcard/2499_com.mobi.filemanager.activity_142051.apk (Permission denied)rn07-24 03:25:07.908: ERROR/D.E. IO(1360): at sfa.mobroad.mdm.function.DownloadCallable.downFile(DownloadCallable.java:114)rn07-24 03:25:07.908: ERROR/D.E. IO(1360): at sfa.mobroad.mdm.function.DownloadCallable.doDownload(DownloadCallable.java:50)rn07-24 03:25:07.908: ERROR/D.E. IO(1360): at sfa.mobroad.mdm.function.DownloadCallable.call(DownloadCallable.java:42)rn07-24 03:25:07.908: ERROR/D.E. IO(1360): at sfa.mobroad.mdm.function.DownloadCallable.call(DownloadCallable.java:1)rn07-24 03:25:07.908: ERROR/D.E. IO(1360): at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:305)rn07-24 03:25:07.908: ERROR/D.E. IO(1360): at java.util.concurrent.FutureTask.run(FutureTask.java:137)rn07-24 03:25:07.908: ERROR/D.E. IO(1360): at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)rn07-24 03:25:07.908: ERROR/D.E. IO(1360): at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:305)rn07-24 03:25:07.908: ERROR/D.E. IO(1360): at java.util.concurrent.FutureTask.run(FutureTask.java:137)rn07-24 03:25:07.908: ERROR/D.E. IO(1360): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1068)rn07-24 03:25:07.908: ERROR/D.E. IO(1360): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:561)rn07-24 03:25:07.908: ERROR/D.E. IO(1360): at java.lang.Thread.run(Thread.java:1096)rnrn我想把一个APK程序下载到SD卡中,但是出了这个错误。rn我在manifest里添加了android.permission.WRITE_EXTERNAL_STORAGE,而且也不是内存不足,因为我用的物理机去做的测试。rnrn我不知道有没有人用过系统签名,我的程序在用系统签名签名之前是可以运行的,但是用调用系统签名之后程序就跑不起来了。。。rn按道理来说系统拥有最高权限,我调用系统签名也是为了实现静默安装,但是没想到在却提示权限不足。rnrn求解,在线等,急!!!!

java.net.SocketException: Permission denied报错

09-24

在AndroidManifest.xml文件中添加还是会报错java.net.SocketException: Permission deniedrnrn本人菜鸟一枚,刚刚接触androidrn还请各位大牛帮忙解决一下,感谢!!!rn一下是源码:rnrn[color=#FF0000][b]MainActivity.java[/b][/color]rnpackage com.example.httptest;rnrnimport android.os.StrictMode;rnimport android.util.Log;rnimport android.support.v7.app.AppCompatActivity;rnimport android.os.Bundle;rnimport android.view.View;rnimport android.content.Intent;rnimport android.content.res.AssetManager;rnimport android.os.AsyncTask;rnimport android.support.v7.app.AppCompatActivity;rnimport android.os.Bundle;rnimport android.widget.TextView;rnimport android.widget.Button;rnrnimport java.io.*;rnimport java.io.BufferedInputStream;rnimport java.io.BufferedOutputStream;rnimport java.io.ByteArrayInputStream;rnimport java.io.ByteArrayOutputStream;rnimport java.io.IOException;rnimport java.io.InputStream;rnimport java.io.OutputStream;rnimport java.io.UnsupportedEncodingException;rnimport java.net.HttpURLConnection;rnimport java.net.MalformedURLException;rnimport java.net.URL;rnimport java.util.HashMap;rnimport java.util.Iterator;rnimport java.util.List;rnimport java.util.Map;rnimport java.util.logging.Handler;rnimport java.util.logging.LogRecord;rnrnimport org.json.*;rnrnpublic class MainActivity extends AppCompatActivity rnrn private TextView textview = null;rn public static String text = null;rnrn @Overridern protected void onCreate(Bundle savedInstanceState) rn super.onCreate(savedInstanceState);rn setContentView(R.layout.activity_main);rn textview = (TextView) findViewById(R.id.textview);rn StrictMode.setThreadPolicy(new StrictMode.ThreadPolicy.Builder().detectDiskReads().detectDiskWrites().detectNetwork().penaltyLog().build());rn rnrnrnrn public void btnOnClick(View view)rn new MyThread().start();rn textview.setText("text");rn rnrnrnclass MyThread extends Threadrn public void run()rn tryrn URL url = new URL("http://192.168.1.104:80/www/text.php");rn HttpURLConnection conn = (HttpURLConnection) url.openConnection();rn conn.setRequestMethod("POST");rn conn.setDoOutput(true);rn conn.setDoInput(true);rn InputStream is = conn.getInputStream();rn MainActivity.text = readInputStream(is);rn catch (MalformedURLException e)rn e.printStackTrace();rn catch (IOException e)rn e.printStackTrace();rn rnrn rnrn public String readInputStream(InputStream is)rn tryrn ByteArrayOutputStream baos = new ByteArrayOutputStream();rn int length = 0;rn byte[] buffer = new byte[1024];rn while ((length = is.read(buffer))!=-1)rn baos.write(buffer,0,length);rn rn is.close();rn baos.close();rn return baos.toString();rn catch (IOException e)rn e.printStackTrace();rn return "failed";rn rn rnrnrn[color=#FF0000][b]AndroidManifest.xml[/b][/color]rnrnrnrn rn rn rn rnrn rn rn rn rn rn rnrnrnrn[color=#FF0000][b]activity_main.xml[/b][/color]rnrnrnrn rnrn rnrnrn

没有更多推荐了,返回首页

私密
私密原因:
请选择设置私密原因
  • 广告
  • 抄袭
  • 版权
  • 政治
  • 色情
  • 无意义
  • 其他
其他原因:
120
出错啦
系统繁忙,请稍后再试