2012/10/18
SSH in CentOS 6.3
SSH 安裝
#sudo yum install openssh-server openssh-clients
SSH 開機時啟動
#sudo /sbin/chkconfig sshd on
SSH 啟動
#sudo /sbin/service sshd start
防火牆設定
#sudo vi /etc/sysconfig/iptables
添加下面一行(範例 port = 22)
-A INPUT -m state --state NEW -m tcp -p tcp --dport 22 -j ACCEPT
重新啟動防火牆
#sudo /sbin/service iptables stop
#sudo /sbin/service iptables start
調整 SSH 設定
#vi /etc/ssh/sshd_config
禁止 root 通過 SSH 登入
PermitRootLogin no
重新啟動
vsftpd 2.2 in CentOS 6.3
安裝 vsftpd
#yum install vsftpd
設定開機啟動 vsftpd ftp
#chkconfig vsftpd on
啟動服務
#service vsftpd start|restart|stop
修改 server port(注意防火牆設定是否完成)
#vi /etc/vsftpd/vsftpd.conf
在最後一行的地方加上: listen_port=21
新增 ftp 使用者
#vi /etc/vsftpd/vsftpd.conf
拿掉以下兩個註解:
chroot_list_enable=YES
chroot_list_file=/etc/vsftpd.chroot_list
增加使用者 ftpuser,指向路徑 /home/wwwroot/ftpuser, 禁止使用 SSH 權限
#useradd -d /home/wwwroot/ftpuser -g ftp -s /sbin/nologin ftpuser
(wwwroot需要先用 mkdir 的方式建立)
修改密碼
#passwd ftpuser
編輯文件chroot_list:
#vi /etc/vsftpd/chroot_list
內容為 ftp 帳號,每個帳號都佔一行:
jeff
nina
登入 ftp 後可轉換至個人目錄
#setsebool -P ftp_home_dir on
配置防火牆
編輯設置文件
#vi /etc/sysconfig/iptables
在REJECT行之前加上以下指令(範例是將 21 port 在防火牆開啟)
-A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp --dport 21 -j ACCEPT
重新啟動防火牆
#service iptables start
2012/10/11
Bluetooth Support Service Setting
Bluetooth Support Service Setting
Part 1 of the solution is buried in this Microsoft Knowledgebase article:
And I quote:
How to make sure that the Bluetooth service is started
- Open the Microsoft Management Console (MMC) snap-in for Services. To do this, follow these steps.
Windows Vista or Windows 7
- Click Start, copy and then paste (or type) the following command in the Start Search box, and then press ENTER: services.msc
- In the Programs list, click Services.
If you are prompted for an administrator password or for confirmation, type the password, or click Continue.Windows XP
- Click Start, and then click Run.
- Copy and then paste (or type) the following command in the Open box, and then press ENTER: services.msc
- Double-click the Bluetooth Support service.
- If the Bluetooth Support service is stopped, click Start.
- On the Startup type list, click Automatic.
- Click the Log On tab.
- Click Local System account.
- Click OK.
- If you prompted to restart the computer, click Yes.
My log on settings were okay, but my Startup Type was set to “Manual” rather than “Automatic”. I changed it, like so:
Bluetooth Power Management Setting
But sadly, my problem wasn’t solved. So then I tried something else. I opened up Device Manager, expanded “Bluetooth Radios”, and double-clicked on the device to open its Properties page – not the enumerator, the device.
Go to the Power Management page and clear the checkbox “Allow the computer to turn off this device to save power”. And finally, relief! No more disconnects. Apparently there is a bug in the power management of the Bluetooth driver under Windows 7.
I can’t say for sure that the first step of making the Bluetooth Support Service automatic is necessary, or just turning off power management would fix it. It doesn’t hurt to change it to automatic so I didn’t test this. If you test it, post your results. Are both changes needed, or do you just need to turn off power management to stop losing connection?
文章來自這裡
訂閱:
文章 (Atom)
NGINX SSL/設定檔案
#user nobody; worker_processes 1; #error_log logs/error.log; #error_log logs/error.log notice; #error_log logs/error.log info; #...
-
Source: Automatically Retry Failed Jobs in Quartz Retrying continuously until success: If you want to keep trying over and over again un...
-
*主餐類 漢堡王炸雞腿-227大卡 華嫩雞條(6PCS)-259大卡 火烤漢堡-311大卡 火烤吉士漢堡-353大卡 小華堡-397大卡 華雪魚-471大卡 雙層吉士漢堡-534大卡 雙層燒烤培根堡-580大卡 華辣雞腿堡-597大卡 華香雞排堡-685大卡...
-
Download source files from here Upload files to the CentOS server Prepare the necessary files #yum -y install gcc gcc-c++ autoconf lib...