nginx - ถึงเวลาซะที
Mount harddisk
Using /dev/disk/by-uuid/:
- Open a terminal.
- Type blkid or ls -l /dev/disk/by-uuid/ and press Enter.
- This will display a list of symlinks, where the filename is the UUID and the target is the device it points to (e.g., lrwxrwxrwx 1 root root 10 Jul 12 12:00 1234-5678 -> ../../sda1).
- Identify the UUID you need and then use the corresponding device path (e.g., /dev/sda1) in other commands if needed.
Edit file /etc/fstab
/dev/disk/by-uuid/50046676-d3fb-6183-54e4-7d65cd58e8ad /mount_name ext4 defaults 0 1
Then update new fstab with command ???
Check harddisk problem
Check with
Repair withfsck /dev/sdax
fsck /dev/sdax -y
Create new user
Update OS
sudo apt update sudo apt upgrade
Check current services running
sudo service --status-all
Step 1 – Installing the Nginx Web Server
Enable HTTP/2 in Nginx on Ubuntu
sudo nano /etc/nginx/sites-available/your_domain
listen 443 ssl http2; listen [::]:443 ssl http2 ipv6only=on;
Step 2 – Installing MariaDB to Manage Site Data
ปรับแต่ง config
nano /etc/mysql/mariadb.conf.d/50-server.cnf
[mysqld] log_slow_query_file = /var/log/mysql/mariadb-slow.log log_slow_query_time = 2 ... innodb_buffer_pool_size = 256M innodb_log_file_size = 128M
ตรวจสอบตารางว่า crash หรือไม่
mariadb-check -u user -p -c database
Step 3 – Installing PHP and Configuring Nginx to Use the PHP Processor => รายละเอียด
ถ้าต้องการถอด php ออก ด้วย
sudo apt-get purge php7.* sudo apt purge php8.* sudo apt-get autoclean sudo apt-get autoremove
Install php 8.3
Relate topics
- nginx on macOS
- PHP PDO using
- การเก็บ JSON ใน MySQL ด้วย PHP
- macOS 12 Monterey: Web Server Setup/Apache/MariaDB/PHP Multiple Versions
- Ubuntu Server Installation
- Bug : isset($body['location']) ดันเป็นจริงเมื่อ $body ไม่ใช่ array
- MVC - แนวคิดเกี่ยวกับ MVC
- FTP chmod
- Hash & Salt
- Regular Expression - ยังไง ยังไง ก็ใช้ไม่ถูกสักที
- PHP : How to show Adsense on web
- PHP : Send SMS by smsgateway.com
- Directadmin PHP path
- Application Programming Interface (API)
- IP Camera snapshot
- Enable Exif
- Make Ubuntu to be a web server (LAMP)
- SELECT - OnChange
- Class fpdf กับภาษาไทย
- มาแล้ว PHP 5.3 พร้อมกับ error ที่ไม่คาดฝัน