[FreeBSD] Ports 更新 index 或 更新kernel

1. cd /usr/ports && make fetchindex
2. portsdb -uU
3. rm -f /var/db/pkg/pkgdb.db
4. pkgdb -Fu
5. cd /usr/src ; make buildworld; make kernel; make installworld; reboot
— 這招很好用 上面步驟如果只需要更新ports tree 只需要 cd /usr/ports && make fetchindex 就可以了

See also