DirectAdmin | 1412 https://xvlnw.com I'm on my way Wed, 22 Feb 2023 16:15:48 +0000 th hourly 1 https://wordpress.org/?v=5.5.13 DirectAdmin กำหนดเวอร์ชั่นของ PHP ตามที่เราต้องการ https://xvlnw.com/topic/968 Tue, 21 Feb 2023 12:33:05 +0000 https://xvlnw.com/?p=968 สำหรับใครที่ build php แล้วไม่สามารถดาวน์โหลดไฟล์จาก File Server ของทาง DirectAdmin ได้ เนื่องจากทาง DirectAdmin ลบ PHP เวอร์ชั่นเก่าออกไป ทำให้ไม่สามารถโหลดได้ วิธีแก้ไขคือ กำหนดเวอร์ชั่นของ PHP ให้เป็นเวอร์ชั่นที่มีอยู่ใน File server ของทาง DirectAdmin เช็คได้ที่ https://files-sg.directadmin.com/s…

The post DirectAdmin กำหนดเวอร์ชั่นของ PHP ตามที่เราต้องการ first appeared on 1412.]]>
สำหรับใครที่ build php แล้วไม่สามารถดาวน์โหลดไฟล์จาก File Server ของทาง DirectAdmin ได้ เนื่องจากทาง DirectAdmin ลบ PHP เวอร์ชั่นเก่าออกไป ทำให้ไม่สามารถโหลดได้ วิธีแก้ไขคือ กำหนดเวอร์ชั่นของ PHP ให้เป็นเวอร์ชั่นที่มีอยู่ใน File server ของทาง DirectAdmin เช็คได้ที่ https://files-sg.directadmin.com/services/custombuild/

cd /usr/local/directadmin/custombuild
echo "php74:7.4.33:" >> custom_versions.txt
./build php n
The post DirectAdmin กำหนดเวอร์ชั่นของ PHP ตามที่เราต้องการ first appeared on 1412.]]>
General error: 1709 Index column size too large. The maximum column size is 767 bytes https://xvlnw.com/topic/956 Wed, 07 Dec 2022 15:17:13 +0000 https://xvlnw.com/?p=956 SQLSTATE[HY000]: General error: 1709 Index column size too large. The maximum column size is 767 bytes สำหรับใครที่สร้าง Indexing แล้วเจอปัญหานี้อยู่ ให้ทำการตั้งค่า my.ini หรือ my.cnf โดยกำหนดค่านี้ลงไป จากนั้นทำการ Restart MySQL/MariaDB แล้วลองดูอีกทีนะครับ

The post General error: 1709 Index column size too large. The maximum column size is 767 bytes first appeared on 1412.]]>
SQLSTATE[HY000]: General error: 1709 Index column size too large. The maximum column size is 767 bytes

สำหรับใครที่สร้าง Indexing แล้วเจอปัญหานี้อยู่ ให้ทำการตั้งค่า my.ini หรือ my.cnf โดยกำหนดค่านี้ลงไป

innodb-default-row-format=dynamic

จากนั้นทำการ Restart MySQL/MariaDB แล้วลองดูอีกทีนะครับ

The post General error: 1709 Index column size too large. The maximum column size is 767 bytes first appeared on 1412.]]>
DirectAdmin กำหนดเวอร์ชั่นของ Nginx เอง https://xvlnw.com/topic/950 Wed, 30 Nov 2022 15:45:52 +0000 https://xvlnw.com/?p=950 Nginx 1.21.6 เป็นเวอร์ชั่นที่สามารถใช้งานกับ srcache + redis cache ได้ https://xvlnw.com/nginx-1.21.6.tar.gz

The post DirectAdmin กำหนดเวอร์ชั่นของ Nginx เอง first appeared on 1412.]]>
cd /usr/local/directadmin/custombuild echo "nginx:1.21.6:" >> custom_versions.txt ./build "nginx"

Nginx 1.21.6 เป็นเวอร์ชั่นที่สามารถใช้งานกับ srcache + redis cache ได้

https://xvlnw.com/nginx-1.21.6.tar.gz

The post DirectAdmin กำหนดเวอร์ชั่นของ Nginx เอง first appeared on 1412.]]>
DirectAdmin เด้งหลุด Login as User https://xvlnw.com/topic/941 Thu, 25 Aug 2022 06:19:16 +0000 https://xvlnw.com/?p=941 สำหรับ DirectAdmin ที่ล็อคอินด้วยสิทธิ์ admin และเข้าไปที่ Login as User อีกที จะมีอาการเด้งหลุดกลับมาที่สิทธิ์ admin บ่อยมากๆ ให้ทำการเพิ่มค่านี้ลงใน directadmin.conf แล้ว Restart DirectAdmin

The post DirectAdmin เด้งหลุด Login as User first appeared on 1412.]]>
สำหรับ DirectAdmin ที่ล็อคอินด้วยสิทธิ์ admin และเข้าไปที่ Login as User อีกที จะมีอาการเด้งหลุดกลับมาที่สิทธิ์ admin บ่อยมากๆ ให้ทำการเพิ่มค่านี้ลงใน directadmin.conf แล้ว Restart DirectAdmin

session_cookie_multiplier=24
The post DirectAdmin เด้งหลุด Login as User first appeared on 1412.]]>
DirectAdmin ติดตั้ง Rspamd กรอง Spam Email https://xvlnw.com/topic/915 Mon, 25 Jul 2022 16:06:09 +0000 https://xvlnw.com/?p=915 Rspamd ตัวกรองอีเมล์ขยะตัวใหม่ ที่เจ๋งและแจ่มกว่า SpamAssassin ซึ่งจะมีระบบ Report ให้เราได้ดูรายการตั้งๆที่ตัว Rspamd ทำงานด้วย แนะนำสำหรับ CentOS 7 ขึ้นไป คำสั้งติดตั้ง Rspamd หลังจากติดตั้งเสร็จแล้ว จะมีเมนู “rspamd spam filtering system” โผล่ขึ้นมาที่สิทธิ์ Admin นะครับ สามารถเข้าไปด…

The post DirectAdmin ติดตั้ง Rspamd กรอง Spam Email first appeared on 1412.]]>
Rspamd ตัวกรองอีเมล์ขยะตัวใหม่ ที่เจ๋งและแจ่มกว่า SpamAssassin ซึ่งจะมีระบบ Report ให้เราได้ดูรายการตั้งๆที่ตัว Rspamd ทำงานด้วย แนะนำสำหรับ CentOS 7 ขึ้นไป

คำสั้งติดตั้ง Rspamd

cd /usr/local/directadmin/custombuild
./build update
./build set eximconf yes
./build set eximconf_release 4.5
./build set dovecot_conf yes
./build set blockcracking yes
./build set easy_spam_fighter yes
./build set spamd rspamd
./build set exim yes
./build rspamd
./build exim
./build exim_conf
./build dovecot
./build dovecot_conf

หลังจากติดตั้งเสร็จแล้ว จะมีเมนู “rspamd spam filtering system” โผล่ขึ้นมาที่สิทธิ์ Admin นะครับ สามารถเข้าไปดูรายงานต่างๆที่ระบบทำงานได้

สำหรับ CentOS 6 หากต้องการติดตั้ง จะต้องอัพเกรด Autoconf ก่อน

# CentOS 6
wget http://ftp.gnu.org/gnu/autoconf/autoconf-latest.tar.gz
tar xzvf autoconf-latest.tar.gz;
cd autoconf-*
./configure
make
make install

และทริปเล็กๆน้อยๆ สำหรับเพิ่มประสิทธิภาพ Rspamd ให้ทำการติดตั้ง Redis Server เพิ่มเติม

pecl install redis
service redis start
service redis restart
chkconfig redis on

จากนั้น ให้ทำการตั้งค่า Rspamd ให้ใช้งาน Redis Server เพื่อทำการแคชข้อมูล เพิ่มประสิทธิภาพในการประมวลผล

nano /etc/rspamd/local.d/redis.conf

# Input here
servers = "127.0.0.1";

# Contrl + X to save

chattr +i /etc/rspamd/local.d/redis.conf

service rspamd restart

หากต้องการตรวจสอบว่า rspamd เชื่อมต่อกับ Redis Server หรือยัง ให้ทำการ Monitor Redis

redis-cli monitor

หากเห็นว่า Rspamd มีการเชื่อมต่อเข้ามาอ่านเขียนข้อมูล ก็เป็นอันเสร็จสิ้นครับ

หากต้องการกลับไปใช้ Spamassassinเหมือนเดิม ให้ใช้คำสั่งนี้

cd /usr/local/directadmin/custombuild
./build set spamd spamassassin
./build spamassassin

service rspamd stop
chkconfig rspamd off
service redis restart
The post DirectAdmin ติดตั้ง Rspamd กรอง Spam Email first appeared on 1412.]]>