https://wiki.debian.org/BridgeNetworkConnections#Introduction





Configuring bridging in /etc/network/interfaces

To make your bridge a little more permanent, you’re gonna need to edit /etc/network/interfaces. Using our example names, make it look like this and you’re set (if you want to use DHCP):

 # This file describes the network interfaces available on your system
 # and how to activate them. For more information, see interfaces(5).

 # The loopback network interface
 auto lo br0
 iface lo inet loopback

 # Set up interfaces manually, avoiding conflicts with, e.g., network manager
 iface eth0 inet manual

 iface eth1 inet manual

 # Bridge setup
 iface br0 inet dhcp
        bridge_ports eth0 eth1

To bring up your bridge, you just have to issue  # ifup br0 and it’ll bring up the other necessary interfaces without anything in your interfaces file about the bridged interfaces.

If you like static IP’s, then you can just add the static IP options under the br0 interface setup. Kinda like this:

 # This file describes the network interfaces available on your system
 # and how to activate them. For more information, see interfaces(5).

 # The loopback network interface
 auto lo br0
 iface lo inet loopback

 # Set up interfaces manually, avoiding conflicts with, e.g., network manager
 iface eth0 inet manual

 iface eth1 inet manual

 # Bridge setup
 iface br0 inet static
        bridge_ports eth0 eth1
        address 192.168.1.2
        broadcast 192.168.1.255
        netmask 255.255.255.0
        gateway 192.168.1.1

Useful options for virtualised environments



[데비안]설치방법-2011-05-05

[데비안]설치방법-2011-05-05.pdf


[우분투]설치방법-2013-08-30

[우분투]설치방법-2013-08-30.pdf


출처 : 

http://www.cellhosting.com/qna.brd/01..108ee5f9/



참고

selinux 를 비활성화 해야함

ipv6 활성화 해야 함

권한 설정을 확인해야 함.

/media/backupHDD/mysql_backup/dbbackup.sh 


#!/bin/sh

time=`date +%Y%m%d%H%M`

mysqldump -u데이터베이스ID -p데이터베이스PW 데이터베이스명 > $time".sql"

WEEKAGO=`date -d "7 days ago" +%Y%m%d`

rm /media/backupHDD/mysql_backup/$WEEKAGO*.sql  // 7일 이전 파일은 삭제

 

매 3시간마다 dbbackup.sh 실행


[root@localhost mysql_backup]# crontab -e
0 */3 * * * root /media/backupHDD/mysql_backup/dbbackup.sh


12:30 분에 dbbackup.sh 실행

30 12 * * * /media/backupHDD/mysql_backup/dbbackup.sh


23:00 분에 dbbackup.sh 실행

00 23 * * * /media/backupHDD/mysql_backup/dbbackup.sh


참고 : http://zetawiki.com/wiki/%EB%A6%AC%EB%88%85%EC%8A%A4_%EB%B0%98%EB%B3%B5_%EC%98%88%EC%95%BD%EC%9E%91%EC%97%85_cron,_crond,_crontab#.EC.98.88.EC.8B.9C

XE의 설치 경로 또는 ./files 디렉토리의 퍼미션이 707이어야 합니다.


SELinux를 비활성화 하면됩니다.


끄기 명령어 : setenforce 0


또는 /etc/sysconfig/selinux 에 SELINUX=disabled  



우분투 sshd 설치

http://zetawiki.com/wiki/%EC%9A%B0%EB%B6%84%ED%88%AC_sshd_%EC%84%A4%EC%B9%98



 우분투 방화벽(UFW) 설정

http://webdir.tistory.com/206

출처 : 마토커닷컴 | http://matoker.com






[Apache] You don't have permission to access / on this server  Linux / Computing 

2013/11/20 14:29

복사http://matoker.com/30179862051

전용뷰어 보기

설치환경

 OS

Cent OS 6.3

 

 

Forbidden
You don't have permission to access / on this server

 

 

위 에러를 직역을 해봐도 단순하게 알수 있지만, 접근 권한이 없다는 내용입니다.

 

아파치 세팅을 무난히 마쳤다고 생각되었음에도 불구하고 위와 같이 메시지가 뜰 경우에

아래의 내용들을 순차적으로 확인 해 볼 필요가 있습니다.

 

 

 

1. 아파치 설정내에 Directory 권한이 제대로 설정이 되어 있는지?

 

아파치 2.2와 아파치 2.4 설정 방법이 다릅니다. 아래의 포스팅을 참고하시기 바랍니다.

 

[Apache] 아파치 2.2 / 아파치 2.4 접근권한 비교

http://matoker.com/30185816358

 

 

 

2. 홈디렉토리의 user/group 이 제대로 부여되었는지? 

 

예를 들어 /home/projects/test_web 이라는 경로를 홈디렉토리로 지정하였는데

test_web 디렉토리 자체는 user/group 이 현재 아파치가 접근 가능하게 지정되어 있는데

/home 또는 /home/projects 디렉토리 자체는 아파치가 접근 가능한 user/group 이 아닌 경우에도

위와 같은 에러가 발생할 수 있습니다.

 

사용자 및 퍼미션을 확인해 보는 명령어는 ls -al 또는 ll 명령어입니다.

 

디렉토리 user/group 을 변경하는 명령어는 아래와 같습니다.

 

chown -R [user명] [디렉토리명]

chgrop -R [group명] [디렉토리명]

chown -R [user명]:[group명] [디렉토리명]

 

-R 옵션은 해당 디렉토리 이하의 모든 폴더 및 파일에 일괄 적용하겠다는 뜻입니다.

 

 

 

3. 홈디렉토리의 퍼미션이 맞게 부여되었는지?

 

사용자 및 퍼미션을 확인해 보는 명령어는 ls -al 또는 ll 명령어입니다.

 

chmod -R [권한] [디렉토리명]

 

권한은 일반적으로 755 정도로 본인의 상황에 맞게 설정하시면 됩니다.

 

 

 

4. SELLINUX 설정이 제대로 안되어 있는 경우


아파치 httpd.conf 에서 Directory 설정을 했음에도 불구하고

접근 권한이 없다고 위처럼 메시지가 나오는 경우 SELLINUX 설정을 의심해 볼 필요가 있습니다.

 

"SELLINUX 란" 하고 검색을 해보면 자세한 설명이 나옵니다.

 

간단하게 말하자면 리눅스의 보안을 강화하기 위해서 최신 리눅스에는 기본적으로 다 탑재가 되어 있는 프로그램입니다.

 

이로 인해 기존에 알고 있던 지식을 바탕으로 세팅을 해주어도 실행이 안되거나, 권한이 없다고 나오는 경우가 있습니다.

이럴때 SELLINUX가 실행되고 있어서인지 확인해 볼 필요가 있습니다.


SELINUX를 사용하지 않으려면

 

setenforce 0

 

이라고 입력하면 사용하지 않게 됩니다.

 

setenforce 1

 

이라고 입력하면 사용하게 됩니다.

위 명령어는 재부팅을 하게 되면 설정값에 따라 다시 적용됩니다.

 

영구적으로 설정하려면 아래의 파일에서 수정을 합니다.

 

vi /etc/sysconfig/selinux

 

 

SELINUX=disabled

 

로 변경합니다.


만일 부분적으로 특정 디렉토리만 제대로 동작하게 하기 위해서는

 

restorecon -rv [디렉토리명]

 

(SELLINUX가 인지 가능하게 라벨링을 복구해주는 작업.. 인듯합니다만 확실하진 않습니다.)


이상으로 포스팅을 마칩니다.

 


마토커닷컴 | http://matoker.com


출처 : http://zetawiki.com/wiki/%EB%A6%AC%EB%88%85%EC%8A%A4_%EC%A2%85%EB%A5%98_%ED%99%95%EC%9D%B8,_%EB%A6%AC%EB%88%85%EC%8A%A4_%EB%B2%84%EC%A0%84_%ED%99%95%EC%9D%B8

리눅스 종류 확인하기
리눅스 버전 확인하기
리눅스 배포판 확인하기

개요

방법 1: rpm

rpm -qa *-release
실행예시 (CentOS 6.2)
[root@zetawiki ~]# rpm -qa *-release
centos-release-6-2.el6.centos.7.x86_64
실행예시 (Fedora 11 Leonidas)
[root@zetawiki ~]# rpm -qa *-release
fedora-release-11-1.noarch
실행예시 (Oracle Enterprise Linux Server 5.5)
[root@zetawiki ~]# rpm -qa *-release
enterprise-release-5-0.0.22
실행예시 (SUSE Linux Enterprise Server 11)
zetawiki:~ # rpm -qa *-release
sles-release-11.1-1.152
lsb-release-2.0-1.2.18

방법 2: /etc/*-release

ll /etc/*-release
cat /etc/*-release | uniq
실행예시 (CentOS 6.2)
[root@zetawiki ~]# ll /etc/*-release
-rw-r--r--. 1 root root 27 Dec  9  2011 /etc/centos-release
lrwxrwxrwx. 1 root root 14 May  7  2012 /etc/redhat-release -> centos-release
lrwxrwxrwx. 1 root root 14 May  7  2012 /etc/system-release -> centos-release
[root@zetawiki ~]# cat /etc/*-release | uniq
CentOS release 6.2 (Final)
실행예시 (Fedora 11 Leonidas)
[root@zetawiki ~]# ll /etc/*-release
-rw-r--r--. 1 root root 29 2009-05-12 07:45 /etc/fedora-release
lrwxrwxrwx. 1 root root 14 2009-10-29 14:53 /etc/redhat-release -> fedora-release
lrwxrwxrwx. 1 root root 14 2009-10-29 14:53 /etc/system-release -> fedora-release
[root@zetawiki ~]# cat /etc/*-release | uniq
Fedora release 11 (Leonidas)
실행예시 (Oracle Enterprise Linux Server 5.5)
[root@zetawiki ~]# ll /etc/*-release
-rw-r--r-- 1 root root 64 Apr  2  2010 /etc/enterprise-release
-rw-r--r-- 1 root root 54 Apr  2  2010 /etc/redhat-release
[root@zetawiki ~]# cat /etc/*-release | uniq
Enterprise Linux Enterprise Linux Server release 5.5 (Carthage)
Red Hat Enterprise Linux Server release 5.5 (Tikanga)
실행예시 (SUSE Linux Enterprise Server 11)
zetawiki:~ # ll /etc/*-release
-rw-r--r-- 1 root root  69 May 12  2010 /etc/SuSE-release
-rw-r--r-- 1 root root 110 May  6  2010 /etc/lsb-release
zetawiki:~ # cat /etc/*-release | uniq
SUSE Linux Enterprise Server 11 (x86_64)
VERSION = 11
PATCHLEVEL = 1
LSB_VERSION="core-2.0-noarch:core-3.2-noarch:core-4.0-noarch:core-2.0-x86_64:core-3.2-x86_64:core-4.0-x86_64"
실행예시 (Ubuntu 12.04.3 LTS)
root@ubuntu:~# ll /etc/*-release
-rw-r--r-- 1 root root 106 Aug 17 14:46 /etc/lsb-release
-rw-r--r-- 1 root root 141 Aug 17 21:47 /etc/os-release
root@ubuntu:~# cat /etc/*-release | uniq
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=12.04
DISTRIB_CODENAME=precise
DISTRIB_DESCRIPTION="Ubuntu 12.04.3 LTS"
NAME="Ubuntu"
VERSION="12.04.3 LTS, Precise Pangolin"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu precise (12.04.3 LTS)"
VERSION_ID="12.04"

방법 3: /etc/issue

명령어
cat /etc/issue
  • 배포판의 버전을 가장 쉽게 확인할 수 있는 방법이다.
  • 보안 등의 이유로 다른 내용으로 바뀌어 있는 경우도 있다.
실행예시 (CentOS 5.7)
[root@zetawiki ~]# cat /etc/issue
CentOS release 5.7 (Final)
Kernel \r on an \m
실행예시 (Fedora 11)
[root@zetawiki ~]# cat /etc/issue
Fedora release 11 (Leonidas)
Kernel \r on an \m (\l)
실행예시 (Oracle Enterprise Linux 5.5)
[root@zetawiki ~]# cat /etc/issue
Enterprise Linux Enterprise Linux Server release 5.5 (Carthage)
Kernel \r on an \m
실행예시 (SUSE Linux Enterprise Server 11)
zetawiki:~ # cat /etc/issue
 
Welcome to SUSE Linux Enterprise Server 11 SP1  (x86_64) - Kernel \r (\l).
실행예시 (Ubuntu 12.04.3 LTS)
root@ubuntu:~# cat /etc/issue
Ubuntu 12.04.3 LTS \n \l

방법 4: uname (커널 버전)

 리눅스 커널 버전 확인 문서를 참고하십시오.
uname -r
실행예시 (Fedora 11, VM)
[root@zetawiki ~]# uname -r
2.6.30.10-105.2.23.fc11.x86_64
실행예시 (CentOS 5.7, Xen VM)
[root@zetawiki ~]# uname -r
2.6.18-274.3.1.el5xen
실행예시 (SUSE Linux Enterprise Server 11, Xen VM)
zetawiki:~ # uname -r
2.6.32.59-0.7-xen
실행예시 (Ubuntu 12.04.3 LTS)
root@ubuntu:~# uname -r
3.8.0-29-generic
root@ubuntu:~# uname -a
Linux ubuntu 3.8.0-29-generic #42~precise1-Ubuntu SMP Wed Aug 14 16:19:23 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux

방법 5: /proc/vesrion (커널 버전)

[root@CentOS64 ~]# cat /proc/version
Linux version 2.6.32-358.el6.x86_64 (mockbuild@c6b8.bsys.dev.centos.org) (gcc version 4.4.7 20120313 (Red Hat 4.4.7-3) (GCC) ) #1 SMP Fri Feb 22 00:31:26 UTC 2013

같이 보기


centos 6.3 minimal 설치시 php-mcrypt 설치

centos 6.3 minimal 설치시 php-mcrypt가 설치 되지 않습니다.
yum으로 찾아 보아도 없다고 나오는군요..
왜 빠졌는지는 모르지만 구글링하다 발견한 내용을 포스팅 합니다.

001
002
003
wget http://ftp.neowiz.com/fedora-epel/6/x86_64/epel-release-6-8.noarch.rpm
rpm -ivh epel-release-6-8.noarch.rpm
yum install php-mcrypt
TAGS





출처 : http://www.9th.kr/?p=112

+ Recent posts