To remember a server migration.

# install apache
sudo apt-get update
sudo apt-get upgrade

sudo apt-get install tasksel
sudo tasksel install lamp-server

curl http://localhost

# install phpmyadmin
sudo apt-get install phpmyadmin
mv /usr/share/phpmyadmin /var/www/html/phpmyadmin

sudo a2enmod rewrite
sudo a2enmod headers
sudo a2enmod expires
sudo a2enmod ssl

# install ssl
sudo apt-get install software-properties-common
sudo add-apt-repository universe
sudo add-apt-repository ppa:certbot/certbot
sudo apt-get update
sudo apt-get install certbot python-certbot-apache
sudo certbot --apache
# renew ssl
sudo certbot renew --dry-run --agree-tos

# create db users, db, upload db
# move html folder
# fix bugs in .htaccess, apache2.config

This above thing serves as a backup in case of future use.

就像早就計劃好的一樣,由於原來的主機即將過期,而我又發現了新的選擇,于是我僅僅續費了 .com 的域名。用了一晚上的時間把數據庫和根目錄備份,然後把這個網站遷移到了AWS的EC2上。經過無數的調試,還算是無縫連接吧。在這裡,基本看不到有什麽區別。


  • 修補遷移帶來的漏洞和問題
  • 添加子頁面,即使之前有一個但被棄用
  • 以後的文章都要添加英文了
  • 可能的話,更換網頁的佈局

這是我的計劃表。謝謝大家,謝謝 Ubuntu,謝謝我。

Like what I had planned before, since the previous hosting plan was about to expire while I found a new choice for that, I only renewed the current .com domain. I spent a night backing up the datadase and the root directory and then I migrated this website to a EC2 plane on AWS, which was a somewhat smooth migration after tons of debugs. The site doesn't look different now.

And now it is about four years since this site was created by me; the site is about to have a new life. I published this post to remember this.

  • fix bugs and errors due to the migration
  • add a sub-site, even if there used to be one
  • English versions of posts will be together with original posts from now on
  • if possible, change the site's theme

This is my schedule. Thanks to all, Ubuntu and me.

One thought on “hello world. AGAIN!