Skip to content

Using package mirrors with mport

Lucas Holt edited this page Aug 22, 2022 · 2 revisions

mport packages are always uploaded to the main server first in the US. However, you can also access them from mirrors. In order to use a mirror, you must configure the mirror_region setting.

This procedure should work on MidnightBSD 1.1 stable or 1.2 release or higher.

Note: the mirror in Japan uses TLS so you should have ca_root_nss installed for certificates to work correctly.

View the current setting

mport config get mirror_region

Examples for each region

mport config set mirror_region jp

mport config set mirror_region uk

mport config set mirror_region us

What mirrors are available?

You can check the current mirror list within the index file downloaded either automatically by mport or by using mport index.

It's a SQLite 3 database file.

sqlite3 /var/db/mport/index.db

select * from mirrors;

You should see output like

jp|https://pub.allbsd.org/MidnightBSD/mports/packages/

uk|http://discovery.midnightbsd.org/mports/packages/

us|http://www.midnightbsd.org/ftp/MidnightBSD/mports/packages/

us2 and us3 mirrors were added for MidnightBSD 2.1+

(then just type control + d to quit the program or type .exit and hit enter)

Clone this wiki locally