another

Error: Another program is already listening on a port that one of our HTTP servers is configured to use. Shut this program down first before starting supervisord.

故事扮演 提交于 2019-11-30 10:22:27
原文出处: https://blog.csdn.net/hyunbar/article/details/80111947 运行 supervisord -c /etc/supervisor/supervisord.conf 出现错误 Starting supervisor: Error: Another program is already listening on a port that one of our HTTP servers is configured to use. Shut this program down first before starting supervisord. For help, use /usr/bin/supervisord -h 解决办法 Terminal上输入 ps -ef | grep supervisord 获取所有supervisord正在运行的pid root 2503 1 0 Nov19 ? 00:03:23 /usr/bin/python /usr/bin/supervisord root 21337 2556 0 18:15 pts/8 00:00:00 grep --color=auto supervisord pid=2503 kill -s SIGTERM 2503 之后在重新执行 supervisord -c /etc

D - Yet Another Problem On a Subsequence CodeForces - 1000D (DP,组合数学)

回眸只為那壹抹淺笑 提交于 2019-11-29 10:00:51
D - Yet Another Problem On a Subsequence CodeForces - 1000D The sequence of integers a1,a2,…,aka1,a2,…,ak is called a good array if a1=k−1a1=k−1 and a1>0a1>0. For example, the sequences [3,−1,44,0],[1,−99][3,−1,44,0],[1,−99] are good arrays, and the sequences [3,7,8],[2,5,4,1],[0][3,7,8],[2,5,4,1],[0] — are not. A sequence of integers is called good if it can be divided into a positive number of good arrays. Each good array should be a subsegment of sequence and each element of the sequence should belong to exactly one array. For example, the sequences [2,−3,0,1,4][2,−3,0,1,4], [1,2,3,−3,−9,4]

LNMP安装常见问题集锦(一)

北战南征 提交于 2019-11-29 07:34:51
LNMP安装常见问题集锦(一) 1、ERROR: invalid PHP executable specified by TEST_PHP_EXECUTABLE = /usr/local/src/php-5.3.18/sapi/cli/php 出现情况: make php过程中的错误 错误意思: 关闭安全模式就好了,都是 safe模式的测试 惹的祸。最新版的php 安装 包中已经没有safe模块了。 解决办法: 该错误可以忽略直接make install 好了。 2、nginx: [emerg] getpwnam("www") failed 出现情况:刚装完nginx后,运行测试文件的时候。 错误意思:获得 www 用户失败。 解决办法:在nginx.conf中 把"#user nobody;"的前面#注释去掉,改为"user www www;" 3、nginx: [error] open() "/usr/local/nginx/logs/nginx.pid" failed (2: No such file or directory) 出现情况:刚 安装 完nginx后重启时报的错。 错误意思: 在 /usr/local/nginx/logs 目录下没有nginx.pid 解决办法: 运行这句话, 问题 解决 " /usr/local/nginx/sbin/nginx -c

Another UDP Server

强颜欢笑 提交于 2019-11-27 23:04:43
// Thanks IBM // http://www.ibm.com/developerworks/linux/tutorials/l-sock2/section5.html #include <stdio.h> #include <stdlib.h> #include <string.h> #include <arpa/inet.h> #include <sys/socket.h> #include <netinet/in.h> #define BUFFSIZE 255 void Die(const char *mess) { perror(mess); exit(1); } int main(int argc, char *argv[]) { int sock; struct sockaddr_in echoserver; struct sockaddr_in echoclient; char buffer[BUFFSIZE]; unsigned int clientlen, serverlen; int received = 0; if (argc != 2) { fprintf(stderr, "USAGE: %s <port>\n", argv[0]); exit(1); } /* Create the UDP socket */ if ((sock = socket

C# Read/Write another Process' Memory

守給你的承諾、 提交于 2019-11-27 20:59:31
https://codingvision.net/security/c-read-write-another-process-memory Today’s tutorial is about…processes’ memory! In this article I’ll show you how to read/write a process’ memory using C#. This is a good way to learn a part of WinAPI and also understand the basics of memory allocation. Before starting, we need a “target” - I choose notepad.exe . 1.Finding the Memory Address As you might probably know, applications store each variable’s value at a specific memory address , we need to know that memory adress in order to edit anything. Since there’s not other way around (or I’m not aware of it?

[ Tools ] [ MobaXterm ] [ SSH ] [ Linux ] export and import saved session

六眼飞鱼酱① 提交于 2019-11-26 18:24:18
How to export MobaXterm sessions to another computer? https://superuser.com/questions/858973/how-to-export-mobaxterm-sessions-to-another-computer 转载于:https://www.cnblogs.com/vincentmylee/p/MobaXterm.html 来源: https://blog.csdn.net/weixin_30367543/article/details/99011468

hdu 3306 Another kind of Fibonacci

流过昼夜 提交于 2019-11-26 14:07:05
Another kind of Fibonacci Time Limit: 3000/1000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others) Total Submission(s): 3509 Accepted Submission(s): 1401 Problem Description As we all known , the Fibonacci series : F(0) = 1, F(1) = 1, F(N) = F(N - 1) + F(N - 2) (N >= 2).Now we define another kind of Fibonacci : A(0) = 1 , A(1) = 1 , A(N) = X * A(N - 1) + Y * A(N - 2) (N >= 2).And we want to Calculate S(N) , S(N) = A(0) 2 +A(1) 2 +……+A(n) 2 Input There are several test cases. Each test case will contain three integers , N, X , Y . N : 2<= N <= 2 31 – 1 X : 2<= X <= 2 31 – 1 Y : 2<= Y <=

Yet Another Array Queries Problem CodeForces - 863D (暴力/思维)

二次信任 提交于 2019-11-26 09:36:17
You are given an array a of size n , and q queries to it. There are queries of two types: 1 l i r i — perform a cyclic shift of the segment [ l i ,  r i ] to the right. That is, for every x such that l i  ≤  x  <  r i new value of a x  + 1 becomes equal to old value of a x , and new value of a l i becomes equal to old value of a r i ; 2 l i r i — reverse the segment [ l i ,  r i ]. There are m important indices in the array b 1 , b 2 , ..., b m . For each i such that 1 ≤  i  ≤  m you have to output the number that will have index b i in the array after all queries are performed. Input The