본문 바로가기

전체 글

(72)
버팔로(Buffalo) DD-WRT PPTP VPN 설정 및 iPhone, iPad 에서 VPN 접속하기. 펌웨어 버전 정보. Firmware: DD-WRT v24-sp2 (03/25/13) std 1. DHCP 설정. 2. PPTP VPN 설정.Server IP: DDWRT의 Local IP Address. ( Setup -> Basic Setup -> Network Setup -> Router IP 에서 확인 가능. )Client IP(s): 192.168.11.10-20 ( VPN Client 에서 접속시 할당되는 IP 앞에 설정으로 하면 순서로 10번부터 20번 까지 할당.)CHAP-Secrets: VPN Client 에서 접속시 사용되는 아이디와 비번 아래 형식으로 입력. 아이디 * 비밀번호 * 예: 아래와 같이 적어넣으면 아이디는 test이고 비밀번호는 test123이다 (*표 사이에 빈칸 하나씩 ..
[NFS mount] touch: cannot touch `1': 허가 거부됨 # mount -t nfs4 192.168.80.1:/ /mnt/Backup# cd /mnt/Backup/# touch 1touch: cannot touch `1': 허가 거부됨 192.168.80.1 서버의 디렉토리에 쓰기 권한이 없어서 허가 거부됨.chmod 755 로 서버쪽의 디렉토리에 사용권한을 부여후 쓰기 가능.
RaspberryPi Openelec Transmission 설치하기. openelec 에서 uTorrent 는 지원 안되지만 transmission torrent 다운로드 프로그램을 지원한다. openelec 설치이후 openelec gui에 접속하여 transmission service 를 설치한다. 아래와 같이 설치하면 된다.settings -> addons -> get addons -> openelec repository -> repositories -> Unofficial addons -> service -> Unofficial transmission *주 처음으로 Unofficial addons repositories 를 설치후 비여 있으면 openelec 를 재부팅하고 다시 접속하면 service가 보인다. 설치완료후 ssh 접속하여 transmission da..
BITWISE OPERAT ORS Operator Description& Bitwise AND operator| Bitwise OR operator^ Bitwise Exclusive OR (XOR) operator~ Bitwise NOT operator, also called the 1’s complement operator>> Bitwise shift right operator>= 4; printf("orignial = %X size= %d \n", original,sizeof(original)); result =4; printf("orignial = %X size= %d \n", original,sizeof(original)); result
if(0) and if(!0) [leechul@~/C_Study]leechul ./iftestwhen if(0)print elsewhen if(!0) print ifa=b [leechul@~/C_Study]leechul cat iftest.c #include #include int main(int argc, char *argv[]) { char a[24] = "test"; char b[24] = "test"; if (0) { printf("when if(0)print if\n"); } else { printf("when if(0)print else\n"); } if (!0) { printf("when if(!0) print if\n"); } else { printf("when if(!) print else\n"); } if (!str..
string functions and operations man string.h 명령어를 사용하여 함수에 대한 내용을 검색. [leechul@~/C_Study]leechul vi 016-string-functions-and-operations.c#include #include int main(int argc, char *argv[]){ char str[24]; char str2[24]; int i; int n; /* Example 1 */ sprintf(str, "Hello World!"); printf("%s\n",str); /* Example 2 */ i = 4; sprintf(str, "Value of i = %d", i); printf("%s\n",str); /* Example 3 */ n = strlen(str); printf("length of st..
multiple-source-files 1. [leechul@leechul 015-multiple-source-files]$ lsaddnumbers.c mian.c[leechul@leechul 015-multiple-source-files]$ gcc -c mian.c [leechul@leechul 015-multiple-source-files]$ gcc -c addnumbers.c [leechul@leechul 015-multiple-source-files]$ lsaddnumbers.c addnumbers.o mian.c mian.o[leechul@leechul 015-multiple-source-files]$ gcc -o main mian.o addnumbers.o[leechul@leechul 015-multiple-source-files]..
typedef [leechul@~/C_Study]leechul cat 014-typedef.c#include typedef int INT32;typedef char MYSTR; typedef struct mystruct_t { int a; int b;} MYSTRX; int main(int argc, char *argv[]) { INT32 i; MYSTR mystr[20] = "Hello World"; MYSTRX gold; MYSTRX silver; MYSTRX bronze; gold.a = 2; gold.b = 4; printf(" i = %d\n", i); printf("mystr = %s\n", mystr); printf("gold.a = %d\n", gold.a); printf("gold.b = %d\n", ..