Quản trị net diễn đàn chia sẻ thông tin các thủ thuật mạng, internet bảo mật thông tin dành cho giới IT VIệt hy vọng là nơi bổ ích cho cộng đồng

Quản trị net diễn đàn chia sẻ thông tin các thủ thuật mạng, internet bảo mật thông tin dành cho giới IT VIệt hy vọng là nơi bổ ích cho cộng đồng (http://quantrinet.com/forum/index.php)
-   Hướng dẫn sử dụng Plesk (http://quantrinet.com/forum/forumdisplay.php?f=195)
-   -   Lỗi Nginx can't start "nginx: [emerg] bind() to failed (99: Cannot assign requested (http://quantrinet.com/forum/showthread.php?t=9433)

hoctinhoc 04-06-2013 08:54 AM

Lỗi Nginx can't start "nginx: [emerg] bind() to failed (99: Cannot assign requested
 
Lỗi Nginx can't start "nginx: [emerg] bind() to failed (99: Cannot assign requested address)""


Vấn đề lỗi này là do khi bạn thay đổi ip trên plesk 10 hoặc plesk 11


Cách giải quyết chạy các lệnh sau


# /usr/local/psa/bin/reconfigurator --autoconfigure
# /usr/local/psa/admin/sbin/httpdmng --reconfigure-all
# /etc/init.d/nginx restart


Nếu với cách lệnh trên mà không chưa fix được lỗi thì bạn có thể vào database của plesk để kiểm tra thêm

Chú ý các lệnh sql bên dưới bạn có thể tham khảo và tuy theo tình huống mà sử dụng cho phù hợp


1. Truy cập database Plesk


#mysql -u admin -p`cat /etc/psa/.psa.shadow ` psa

2. Show ip trong bản IP_Addresses

""""""""""""""
mysql> select * from IP_Addresses;
+----+---------------+-----------------+-----------------+--------+--------------------+-------------------+-------+------+--------+
| id | serviceNodeId | ip_address | mask | iface | ssl_certificate_id | default_domain_id | ftps | main | status |
+----+---------------+-----------------+-----------------+--------+--------------------+-------------------+-------+------+--------+
| 2 | 1 | 210.211.117.215 | 255.255.255.255 | venet0 | 2 | 0 | false | true | 0 |
+----+---------------+-----------------+-----------------+--------+--------------------+-------------------+-------+------+--------+
1 row in set (0.00 sec)

mysql>

"""""""""""""""""

3. Show ip trong bản ip_pool


++++++++++++
mysql> select * from ip_pool;
+----+---------------+--------+
| id | ip_address_id | type |
+----+---------------+--------+
| 1 | 1 | shared |
| 1 | 2 | shared |
+----+---------------+--------+
++++++++++++

4. Xóa ip có IP_address_id =1 trong bản ip_pool

+++++++++
mysql> delete from ip_pool where ip_address_id=1;
Query OK, 1 row affected (0.02 sec)
+++++++++

5. Show id, ip_address, iface trong bản IP_Addresses

++++++++++++++
mysql> select id, ip_address, iface from IP_Addresses where id in (1,2,3);
+----+-----------------+--------+
| id | ip_address | iface |
+----+-----------------+--------+
| 2 | 210.211.117.215 | venet0 |
+----+-----------------+--------+
1 row in set (0.00 sec)

mysql>
++++++++++

6. Xóa ip_address_id=2 trong bản ip_pool


mysql> delete from ip_pool where ip_address_id=2;


7. thay đổi id=1 cho ip_addpress 210.211.117.215 trong bản IP_Addresses



#mysql> update IP_Addresses set id='1' where ip_address='210.211.117.215';



Chúc thành công!

:battay:


Bây giờ là 01:28 AM. Giờ GMT +7

Diễn đàn tin học QuantriNet
quantrinet.com | quantrimang.co.cc
Founded by Trương Văn Phương | Developed by QuantriNet's members.
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.