Sample Header Ad - 728x90

Unix & Linux Stack Exchange

Q&A for users of Linux, FreeBSD and other Unix-like operating systems

Latest Questions

0 votes
1 answers
23 views
Libclang not found running poudriere
I’ve got a program that I wrote in Rust, to help me keep track of finances, as well as read/write the data that comes from an iOS app that I made to do the same thing, and I’m running into an issue. On FreeBSD, I can compile it just fine without any issues, but when I go to turn it into a port and t...
I’ve got a program that I wrote in Rust, to help me keep track of finances, as well as read/write the data that comes from an iOS app that I made to do the same thing, and I’m running into an issue. On FreeBSD, I can compile it just fine without any issues, but when I go to turn it into a port and test the port in poudriere, it complains that it cannot find libclang at all, even if I specify it in LIB_DEPEND, even though it is supposed to be present in the base of FreeBSD. The jail used by poudriere and the host are both running version 14.3. I did also see that there was indeed nothing in the location that typically holds libclang.so inside the jail, but in cases like those, I thought that it would have grabbed the port I specified according to the Porter’s handbook for LIB_DEPEND. Does anybody have an idea on how to solve this?
user1013391 (11 rep)
Jul 26, 2025, 03:23 AM • Last activity: Jul 28, 2025, 01:51 PM
1 votes
1 answers
38 views
How to create a mutually exclusive FreeBSD port?
I have created multiply FreeBSD ports of a program, that supports different database flavours (e.g. PostgreSQL, MariaDB, ...). That part is working perfectly fine. Now I want to create a dependency to all the different program-database ports, but only one should be selected. I know how to add depend...
I have created multiply FreeBSD ports of a program, that supports different database flavours (e.g. PostgreSQL, MariaDB, ...). That part is working perfectly fine. Now I want to create a dependency to all the different program-database ports, but only one should be selected. I know how to add dependencies to a port with BUILD_DEPENDS and RUN_DEPENDS, but don't know how to make a list mutual exclusive?
ByteNudger (767 rep)
Nov 23, 2024, 02:56 PM • Last activity: Nov 23, 2024, 08:31 PM
3 votes
1 answers
1334 views
OpenBSD: Where to seek for the source of programs in the base system?
In OpenBSD, I use `pkg_info -E $(which [cmd])` to be supplied with the name of the package/port to the executable/command `[cmd]`. Having this information I can further look for the source code to the software. However, there are some utilities that seem to be shipped with the base install of OpenBS...
In OpenBSD, I use pkg_info -E $(which [cmd]) to be supplied with the name of the package/port to the executable/command [cmd]. Having this information I can further look for the source code to the software. However, there are some utilities that seem to be shipped with the base install of OpenBSD, such as the netstat utility. Where would I go about finding the source code of such programs?
fraleone (897 rep)
Jan 20, 2020, 11:20 AM • Last activity: Apr 25, 2024, 04:50 PM
0 votes
2 answers
1783 views
Install pkg for FreeBSD 10
I'm getting the following error while trying to install [pkg][1] on FreeBSD 10.4- Bootstrapping pkg from pkg+http://pkg.FreeBSD.org/FreeBSD:10:amd64/latest, please wait... pkg: Error fetching http://pkg.FreeBSD.org/FreeBSD:10:amd64/latest/Latest/pkg.txz: Not Found A pre-built version of pkg could no...
I'm getting the following error while trying to install pkg on FreeBSD 10.4- Bootstrapping pkg from pkg+http://pkg.FreeBSD.org/FreeBSD:10:amd64/latest , please wait... pkg: Error fetching http://pkg.FreeBSD.org/FreeBSD:10:amd64/latest/Latest/pkg.txz : Not Found A pre-built version of pkg could not be found for your system. Consider changing PACKAGESITE or installing it from ports: 'ports-mgmt/pkg'. When I try to install it using ports, I get the following error- set: Illegal option -o pipefail ===> Options unchanged set: Illegal option -o pipefail *** Error code 2 Stop. make[1] : stopped in /data/usr/ports/ports-mgmt/pkg *** Error code 1 Stop. make: stopped in /data/usr/ports/ports-mgmt/pkg Is there any other way to install pkg or change default repo URL to download packages?
Shradha (109 rep)
May 29, 2022, 07:39 PM • Last activity: Nov 12, 2023, 05:05 PM
1 votes
1 answers
1424 views
How can I use cloud-init NoCloud with OPNsense 21?
I'm new to OPNSense (also to FreeBSD in general) and I'm interested to use cloud-init to configure at least LAN (vtnet0) with static ip address, root password and eventually running custom scripts (or shell commands) in a OPNsense VM created with Qemu to apply a custom configuration. I saw that opns...
I'm new to OPNSense (also to FreeBSD in general) and I'm interested to use cloud-init to configure at least LAN (vtnet0) with static ip address, root password and eventually running custom scripts (or shell commands) in a OPNsense VM created with Qemu to apply a custom configuration. I saw that opnsense github repo has cloud-init port , so I installed it with: pkg install net/cloud-init Then I added cidata.iso image to Qemu as required by cloud-init NoCloud with user-data and meta-data. I already tested those files on ubuntu server 21 and kali linux. They are correct at least on those OSs ;) I found the cdrom as /dev/cd0 and mounted with mkdir -p /media/cdrom mount -t cd9660 /dev/cd0 /media/cdrom I also edited /etc/fstab appending this line: /dev/cd0 /media/cdrom cd9660 ro 0 0 to auto mount the cdrom at boot. Finally, I created (because unexisting) /etc/rc.conf with this content: cloudinit_enable="YES" and restarted my OPNsense VM. What I expect now is that cloud-init will start automatically at boot. However this doesn't happen, probably because I have to configure something. If I run cloud-init init via terminal it throws error: stages.py[WARNING]: Failed to rename devices: Unexpected error while running command. Command [ip, -6, addr,show, permanent, scope,global] Exit code: - Reason: [Errno 2] No such file or directory: bip Stdout: - Stderr: - No init modules to run under section cloud_init_modules On both Kali Linux and Ubuntu Server it works easely. I have some questions about this: 1) Is it possible to use cloud-init port with NoCloud and a cdrom (cidata) with configuration files or it supports only Cloud services with OpenStack and so on? 2) Is my configuration above correct or am I missing something? 3) Why does it appear the error above? How can I fix it? I already posted this question here , but I didn't receive answers.
Stefano Cappa (151 rep)
Oct 7, 2021, 02:38 PM • Last activity: Jul 10, 2023, 10:46 PM
5 votes
2 answers
3830 views
How to install PostgreSQL 9.3 in FreeBSD jail?
I configured virtual NICS using `pf`, and a jail for FreeBSD using `qjail create pgsql-jail 192.168.0.3`. When I tried to install PostgreSQL 9.3 using port collection, it shows strange message at first. pgsql-jail /usr/ports/databases/postgresql93-server >make install ===> Building/installing dialog...
I configured virtual NICS using pf, and a jail for FreeBSD using qjail create pgsql-jail 192.168.0.3. When I tried to install PostgreSQL 9.3 using port collection, it shows strange message at first. pgsql-jail /usr/ports/databases/postgresql93-server >make install ===> Building/installing dialog4ports as it is required for the config dialog ===> Cleaning for dialog4ports-0.1.5_1 ===> Skipping 'config' as NO_DIALOG is defined ====> You must select one and only one option from the KRB5 single *** [check-config] Error code 1 Stop in /basejail/usr/ports/ports-mgmt/dialog4ports. *** [install] Error code 1 Stop in /basejail/usr/ports/ports-mgmt/dialog4ports. ===> Options unchanged => postgresql-9.3.0.tar.bz2 doesn't seem to exist in /var/ports/distfiles/postgresql. => Attempting to fetch ftp://ftp.se.postgresql.org/pub/databases/relational/postgresql/source/v9.3.0/postgresql-9.3.0.tar.bz2 postgresql-9.3.0.tar.bz2 1% of 16 MB 71 kBps Anyway, installation continues, so I waited. I chose all default options for all option dialogs. And at the end of the process, I saw it finally failed with this message. ====> Compressing man pages ===> Building package for pkgconf-0.9.3 Creating package /basejail/usr/ports/devel/pkgconf/pkgconf-0.9.3.tbz Registering depends:. Registering conflicts: pkg-config-*. Creating bzip'd tar ball in '/basejail/usr/ports/devel/pkgconf/pkgconf-0.9.3.tbz' tar: Failed to open '/basejail/usr/ports/devel/pkgconf/pkgconf-0.9.3.tbz' pkg_create: make_dist: tar command failed with code 256 *** [do-package] Error code 1 Stop in /basejail/usr/ports/devel/pkgconf. *** [build-depends] Error code 1 Stop in /basejail/usr/ports/textproc/libxml2. *** [install] Error code 1 Stop in /basejail/usr/ports/textproc/libxml2. *** [lib-depends] Error code 1 Stop in /basejail/usr/ports/databases/postgresql93-server. *** [install] Error code 1 Stop in /basejail/usr/ports/databases/postgresql93-server. I have no idea why this fails. Errors at beginning seems I have something wrong with dialog4ports. And errors at last seems installer cannot write to ports file tree. AFAIK, the ports files are read-only shared from host system. What's wrong with my jail? How can install PostgreSQL 9.3 in my jail?
Eonil (4777 rep)
Oct 7, 2013, 03:29 PM • Last activity: May 16, 2023, 04:10 PM
0 votes
1 answers
818 views
rsnapshot.conf - reducing verbose parameter not having the desired effect?
TL;DR Is there some configuration for rsnapshot (see versions below) that would allow me to restrict output to the shell commands, errors and start/finish notifications generated by rsnapshot itself, while causing rsync to generate and record the desired level of detail *only* in the rsync log file?...
TL;DR Is there some configuration for rsnapshot (see versions below) that would allow me to restrict output to the shell commands, errors and start/finish notifications generated by rsnapshot itself, while causing rsync to generate and record the desired level of detail *only* in the rsync log file? Or put more succinctly, can I make the results of rsnapshot output match the descriptions of verbosity in the rsnapshot config file? If not, is there an rsnapshot community that takes feature requests? Just the TL part... It appears after some troubleshooting (see below) that my particular combination of rsnapshot and rsync no longer works as it did for the previous several years. Specifically, the output from rsync now shows up in the console output of rsnapshot, regardless of the verbose settings in rsnapshot.conf. I have a fresh install of FreeBSD 12.2
freebsd-version   
12.2-RELEASE-p10
rsync was installed as part of pkg install rsnapshot, and rsync -V shows
rsync  version 3.2.3  protocol version 31
Copyright (C) 1996-2020 by Andrew Tridgell, Wayne Davison, and others.
Web site: https://rsync.samba.org/ 
Capabilities:
    64-bit files, 64-bit inums, 64-bit timestamps, 64-bit long ints,
    socketpairs, hardlinks, hardlink-specials, symlinks, IPv6, atimes,
    batchfiles, inplace, append, ACLs, xattrs, optional protect-args, iconv,
    symtimes, no prealloc, stop-at, no crtimes, file-flags
Optimizations:
    no SIMD, no asm, openssl-crypto
Checksum list:
    xxh128 xxh3 xxh64 (xxhash) md5 md4 none
Compress list:
    zstd lz4 zlibx zlib none
current version of rsnapshot is:
# version of rsnapshot
my $VERSION = '1.4.4';
The issue, after posting the original form of this question, and sleeping on it, plus the aforementioned troubleshooting, boils down to this: rsnapshot runs from crontab, and the unnecessary information from rsync appearing in the console output (despite the verbose 1 setting) seems to requires a "wrapper" script to suppress the noise, and then assemble the correct information from the rsnapshot log. This seems like a very error-prone process, and one that is also likely to be very high-maintenance, as upgrades break the duct-tape nature of the workaround. The least-cost path seems to be to give up on getting any stats information on the effectiveness of the rsync transfer. This allows me to maintain readability for monitoring the success/failure of the rsync, and to easily re-run it when it does fail. Clearly something has changed, I suspect with rsync (an implicit -v setting?), and if there's some configuration that would allow me to get what I want in the rsnapshot output (only the shell commands, errors and start/finish notifications) while recording the rsync output in the rsync log file, I'd sure love to know about it. Please keep in mind the rsnapshot regime has been running perfectly since 2018, and only doing a fresh install of FreeBSD 12.2 broke it. The previous rsnapshot regime was running (on the same hardware) on an upgraded FreeBSD 12.1 (started as 10.x). rsync and rsnapshot were originally built separately (in that order) from the FreeBSD 10.x ports, and upgraded regularly since then with portmaster. This time (as mentioned) I installed rsnapshot with pkg, and let it install rsync (and everything else it neeeded). rsnapshot.conf changed only in the value of snapshot_root and a shortened list of backup points. Here's the output I want (easy-to-process) for the monitoring emails (that is, without all the rsync noise):
Wed Oct 20 21:40:00 PDT 2021
=================================================================

echo 98875 > /var/run/rsnapshot.pid 
mv /obo-offsitepool/archives/daily.5/ /obo-offsitepool/archives/daily.6/ 
mv /obo-offsitepool/archives/daily.4/ /obo-offsitepool/archives/daily.5/ 
mv /obo-offsitepool/archives/daily.3/ /obo-offsitepool/archives/daily.4/ 
mv /obo-offsitepool/archives/daily.2/ /obo-offsitepool/archives/daily.3/ 
mv /obo-offsitepool/archives/daily.1/ /obo-offsitepool/archives/daily.2/ 
native_cp_al("/obo-offsitepool/archives/daily.0", \
    "/obo-offsitepool/archives/daily.1") 
/usr/local/bin/rsync -a --delete --numeric-ids \
    /obo-offsitepool/archives/daily.0/ /obo-offsitepool/archives/daily.1/ 
/usr/local/bin/rsync -rltv --chmod D0770,F0660 --delete --relative \
    --delete-excluded --partial --stats --log-file=/var/log/rsync \
    --human-readable \
    --exclude-from=/obo-offsitepool/archives/.rsnapshot_excludes \
    /usr/local/etc/ \
    /obo-offsitepool/archives/daily.0/obo-offsite1/local_etc/ 
/usr/local/bin/rsync -rltv --chmod D0770,F0660 --delete --relative \
    --delete-excluded --partial --stats --log-file=/var/log/rsync \
    --human-readable \
    --exclude-from=/obo-offsitepool/archives/.rsnapshot_excludes \
    192.168.18.3::srv330-group/ \
    /obo-offsitepool/archives/daily.0/CSO/srv330-group 
... etc
Rather than this (keeping in mind there are >20 backup points, many with hundreds of lines of unwanted rsync output):
Tue Oct 26 18:55:00 PDT 2021
=================================================================

echo 97810 > /var/run/rsnapshot.pid 
/bin/rm -rf /obopool/archives/daily.6/ 
mv /obopool/archives/daily.5/ /obopool/archives/daily.6/ 
mv /obopool/archives/daily.4/ /obopool/archives/daily.5/ 
mv /obopool/archives/daily.3/ /obopool/archives/daily.4/ 
mv /obopool/archives/daily.2/ /obopool/archives/daily.3/ 
mv /obopool/archives/daily.1/ /obopool/archives/daily.2/ 
native_cp_al("/obopool/archives/daily.0", \
    "/obopool/archives/daily.1") 
/usr/local/bin/rsync -a --delete --numeric-ids \
    /obopool/archives/daily.0/ /obopool/archives/daily.1/ 
/usr/local/bin/rsync -rltv --chmod D0770,F0660 --delete --relative \
    --delete-excluded --partial --stats --log-file=/var/log/rsync \
    --human-readable \
    --exclude-from=/obopool/archives/.rsnapshot_excludes /usr/local/etc/ \
    /obopool/archives/daily.0/offsite1/local_etc/ 
sending incremental file list
/usr/
deleting usr/local/etc/ssmtp/ssmtp.conf.sample
deleting usr/local/etc/ssmtp/ssmtp.conf.2021-01-20
deleting usr/local/etc/ssmtp/ssmtp.conf
deleting usr/local/etc/ssmtp/revaliases.sample
deleting usr/local/etc/ssmtp/revaliases
deleting usr/local/etc/ssmtp/
deleting usr/local/etc/dma/dma.conf.sample
deleting usr/local/etc/dma/dma.conf
deleting usr/local/etc/dma/auth.conf.sample
deleting usr/local/etc/dma/auth.conf
deleting usr/local/etc/dma/
deleting usr/local/etc/portmaster.rc.sample
deleting usr/local/etc/papersize.letter
deleting usr/local/etc/papersize.a4
deleting usr/local/etc/bash_completion.d/portmaster.sh
deleting usr/local/etc/rc.d/dma_flushq
/usr/local/
/usr/local/etc/
/usr/local/etc/rsnapshot.conf
/usr/local/etc/rsnapshot.conf.default
/usr/local/etc/rsnapshot.conf_2018-09-08
/usr/local/etc/rsnapshot.conf_2019-06-14
/usr/local/etc/rsnapshot.conf_2019-08-23
/usr/local/etc/rsnapshot.conf_2021-02-01
/usr/local/etc/rsnapshot.conf_2021-06-21
/usr/local/etc/screenrc
/usr/local/etc/screenrc.sample
/usr/local/etc/smartd.conf
/usr/local/etc/smartd.conf.sample
/usr/local/etc/smartd_warning.sh
/usr/local/etc/bash_completion.d/
/usr/local/etc/man.d/
/usr/local/etc/man.d/perl5.conf
/usr/local/etc/newsyslog.conf.d/
/usr/local/etc/newsyslog.conf.d/rsnapshot
/usr/local/etc/newsyslog.conf.d/rsync
/usr/local/etc/newsyslog.conf.d/rsyncd
/usr/local/etc/periodic/
/usr/local/etc/periodic/daily/
/usr/local/etc/periodic/daily/smart
/usr/local/etc/periodic/security/
/usr/local/etc/periodic/weekly/
/usr/local/etc/rc.d/
/usr/local/etc/rc.d/rsyncd
/usr/local/etc/rc.d/smartd
/usr/local/etc/rc.d/uuidd
/usr/local/etc/rsync/
/usr/local/etc/rsync/rsyncd.conf
/usr/local/etc/rsync/rsyncd.conf.sample
/usr/local/etc/smartd_warning.d/
/usr/local/etc/ssl/
/usr/local/etc/ssl/cert.pem

Number of files: 46 (reg: 31, dir: 14, link: 1)
Number of created files: 4 (reg: 3, dir: 1)
Number of deleted files: 16 (reg: 14, dir: 2)
Number of regular files transferred: 23
Total file size: 774.49K bytes
Total transferred file size: 735.92K bytes
Literal data: 735.92K bytes
Matched data: 0 bytes
File list size: 0
File list generation time: 0.001 seconds
File list transfer time: 0.000 seconds
Total bytes sent: 738.45K
Total bytes received: 1.10K

sent 738.45K bytes  received 1.10K bytes  1.48M bytes/sec
total size is 774.49K  speedup is 1.05
/usr/local/bin/rsync -rltv --chmod D0770,F0660 --delete --relative \
    --delete-excluded --partial --stats --log-file=/var/log/rsync \
    --human-readable \
    --exclude-from=/obopool/archives/.rsnapshot_excludes \
    192.168.18.3::srv330-group/ \
    /obopool/archives/daily.0/CSO/srv330-group 
receiving incremental file list
CSO2/Lori/
CSO2/Lori/retail.prices2.docx
Retail/
...etc
**Both of the above email reports were produced from the same rsnapshot.conf file.** Here's the troubleshooting I've been doing. Test 4 is the best approximation to what I had previously.
1
rsnapshot -v alpha && /root/scripts/marklogs.sh --> using default rsnapshot.conf with 
 entries for rsync_short_args AND rsync_long_args  were actually elided from file (not left with # symbol)
 - normal screen output (start notification, shell commands, success notification)
 - rsnapshot log shows same as monitor output, no rsync log output

2 Explicitly add in default settings to the rsnapshot.conf file  
rm -rf  /obopool/tester/alpha* && rsnapshot -v alpha  && /root/scripts/marklogs.sh #--> rsnapshot.conf modifed as shown:
 rsync_short_args        -a
 rsync_long_args         --delete --numeric-ids --relative --delete-excluded
  - same as previous 

3 change rsync_long_args
rm -rf  /obopool/tester/alpha* && rsnapshot -v alpha  && /root/scripts/marklogs.sh #--> rsnapshot.conf modifed from default as shown:
 rsync_short_args        -a
 rsync_long_args         --chmod D0770,F0660 --delete --relative --delete-excluded --partial --log-file=/var/log/rsync-test
 - console shows expected output (start notification, shell commands, success confirmations)
 - rsnapshot log shows same as monitor output
 - rsync log shows building file list, files xferred, sent/received/total summary line for each backup point
 
4 change rsync_short args
rm -rf  /obopool/tester/alpha* && rsnapshot -v alpha && /root/scripts/marklogs.sh  #--> rsnapshot.conf modifed from default as shown:
 rsync_short_args        -rlt
 rsync_long_args         --chmod D0770,F0660 --delete --relative --delete-excluded --partial --log-file=/var/log/rsync-test
 - normal console output (start notification, shell commands, success notification)
 - rsnapshot log shows same as console
 - rsync log shows building file list, files xferred, sent/received/total summary line for each backup point

5 change rsync_short_arg to add -v
rm -rf  /obopool/tester/alpha* && rsnapshot -v alpha && /root/scripts/marklogs.sh  #--> rsnapshot.conf modifed from default as shown:
 rsync_short_args        -rltv
 rsync_long_args         --chmod D0770,F0660 --delete --relative --delete-excluded --partial --log-file=/var/log/rsync-test
 - console shows the unexpected (and undesired), given verbose set at 2, rsync output
 - rsnapshog log is polluted with rsync output, shows the start notification & shell commands before the noise, then some closing shell commands (touch /obopool/tester/alpha.0/; rm -f /var/run/rsnapshot.pid) then the completion notification
 - rsync log adds one line, "total size ..... speedup is .....", to logged info.
  
6 change loglevel to 1 to see effect on rsnapshot log
rm -rf  /obopool/tester/alpha* && rsnapshot -v alpha && /root/scripts/marklogs.sh  #--> rsnapshot.conf modifed from default as shown:
 loglevel	               1
 rsync_short_args        -rltv
 rsync_long_args         --chmod D0770,F0660 --delete --relative --delete-excluded --partial --log-file=/var/log/rsync-test
 - console shows same polluted output (rsnapshot shell commands with rsync data)
 - rsnapshot log received no ouput
 - rsync log shows same (correct) output as previous execution

7 change verbose to 1 (quiet) in rsnapshot.conf
rm -rf  /obopool/tester/alpha* && rsnapshot -v alpha && /root/scripts/marklogs.sh  #--> rsnapshot.conf modifed as shown:
 verbose                 1
 loglevel	               1
 rsync_short_args        -rltv
 rsync_long_args         --chmod D0770,F0660 --delete --relative --delete-excluded --partial --log-file=/var/log/rsync-test
 - console - no change to output from test 6 
 - rsnapshot log received no ouput (expected with loglevel 1)
 - rsync log shows expected output (same as previous)

8 set loglevel to 2 to verify effect on rsnapshot log
rm -rf  /obopool/tester/alpha* && rsnapshot -v alpha && /root/scripts/marklogs.sh  #--> rsnapshot.conf modifed as shown:
 verbose                 1
 loglevel	               2
 rsync_short_args        -rltv
 rsync_long_args         --chmod D0770,F0660 --delete --relative --delete-excluded --partial --log-file=/var/log/rsync-test
 - console - no change
 - rshapshot log shows only start and completion notices (no shell commands). One assumes errors would show up.
 - rsync log shows expected output

9 variation on 4: default verbose/log level - no -v on rsync_short_args, and add --stats to rsync long args
rm -rf  /obopool/tester/alpha* && rsnapshot -v alpha && /root/scripts/marklogs.sh  #--> rsnapshot.conf modifed from default as shown:
 rsync_short_args        -rlt
 rsync_long_args         --chmod D0770,F0660 --delete --relative --delete-excluded --partial --log-file=/var/log/rsync-test --stats
 - console has stats (rsync) information mixed in with correct output (start notification, shell commands, success confirmations)
 - rshapshot log has the same issues as console: stats output mixed in with  expected output (start notification, shell commands, success confirmations)
 - rsync log shows expected output -- files plus stats.
This is the default (installed) /usr/local/etc/rsnapshot.conf file, against which all the logged changes were made.
#/usr/local/etc/rsnapshot.conf
#################################################
# rsnapshot.conf - rsnapshot configuration file #
#################################################
#                                               #
# PLEASE BE AWARE OF THE FOLLOWING RULE:        #
#                                               #
# This file requires tabs between elements      #
#                                               #
#################################################

#######################
# CONFIG FILE VERSION #
#######################

config_version  1.2
snapshot_root   /obopool/tester
no_create_root  1
cmd_rm          /bin/rm
cmd_rsync       /usr/local/bin/rsync
cmd_logger      /usr/bin/logger
#cmd_rsnapshot_diff     /usr/local/bin/rsnapshot-diff

retain  alpha   6
retain  beta    7
retain  gamma   4
#retain delta   3

# Verbose level, 1 through 5.
# 1     Quiet           Print fatal errors only
# 2     Default         Print errors and warnings only
# 3     Verbose         Show equivalent shell commands being executed
# 4     Extra Verbose   Show extra verbose information
# 5     Debug mode      Everything
#
verbose         2

# Same as "verbose" above, but controls the amount of data sent to the
# logfile, if one is being used. The default is 3.
#
loglevel        3

logfile /var/log/rsnapshot-test
lockfile        /var/run/rsnapshot.pid


###############################
### BACKUP POINTS / SCRIPTS ###
###############################

# LOCALHOST
backup  /root/          localhost/
backup  /etc/           localhost/
backup  /usr/local/     localhost/
backup  /var/log/       localhost/
and finally, here's a bit of the perl -V output
perl -V
Summary of my perl5 (revision 5 version 32 subversion 1) configuration:
   
  Platform:
    osname=freebsd
    osvers=12.2-release-p10
    archname=amd64-freebsd-thread-multi
    uname='freebsd 122amd64-quarterly-job-03 12.2-release-p10 freebsd 12.2-release-p10 amd64 '
    config_args='-Darchlib=/usr/local/lib/perl5/5.32/mach -Dcc=cc -Dcf_by=mat -Dcf_email=mat@FreeBSD.org -Dcf_time=Sat Jan 23 14:56:40 UTC 2021 -Dinc_version_list=none -Dlibperl=libperl.so.5.32.1 -Dman1dir=/usr/local/lib/perl5/5.32/perl/man/man1 -Dman3dir=/usr/local/lib/perl5/5.32/perl/man/man3 -Dprefix=/usr/local -Dprivlib=/usr/local/lib/perl5/5.32 -Dscriptdir=/usr/local/bin -Dsitearch=/usr/local/lib/perl5/site_perl/mach/5.32 -Dsitelib=/usr/local/lib/perl5/site_perl -Dsiteman1dir=/usr/local/lib/perl5/site_perl/man/man1 -Dsiteman3dir=/usr/local/lib/perl5/site_perl/man/man3 -Dusenm=n -Duseshrplib -sde -Ui_iconv -Ui_malloc -Uinstallusrbinperl -Accflags=-DUSE_THREAD_SAFE_LOCALE -Alddlflags=-L/wrkdirs/usr/ports/lang/perl5.32/work/perl-5.32.1 -L/usr/local/lib/perl5/5.32/mach/CORE -lperl -Dshrpldflags=$(LDDLFLAGS:N-L/wrkdirs/usr/ports/lang/perl5.32/work/perl-5.32.1:N-L/usr/local/lib/perl5/5.32/mach/CORE:N-lperl) -Wl,-soname,$(LIBPERL:R) -Doptimize=-O2 -pipe  -fstack-protector-strong -fno-strict-aliasing  -Dusedtrace -Ui_gdbm -Dusemultiplicity=y -Duse64bitint -Dusemymalloc=n -Dusethreads=y'
BISI (136 rep)
Oct 28, 2021, 04:55 AM • Last activity: Nov 3, 2021, 06:17 PM
0 votes
2 answers
587 views
Change ports mirror in FreeBSD
The initial portsnap fetch command is talking forever. I'm getting speeds of 3427 Bps. Bps. So 3.4 KBps. Where's the config to change the mirror. Please note I'm not talking about the actual building in ports, that's fine. I'm talking about downloading the ports tree.
The initial portsnap fetch command is talking forever. I'm getting speeds of 3427 Bps. Bps. So 3.4 KBps. Where's the config to change the mirror. Please note I'm not talking about the actual building in ports, that's fine. I'm talking about downloading the ports tree.
Andy Chow (103 rep)
Apr 13, 2021, 12:20 PM • Last activity: Apr 15, 2021, 07:42 AM
3 votes
2 answers
1106 views
How do I enable options for installed Ports in FreeBSD?
I installed the Vim editor using Ports and in the process didn't enable GTK2 or GNOME option. I assume that either these 2 options will let me use `gvim`. Here's my `pkg info vim`: vim-7.4.430_1 Name : vim Version : 7.4.430_1 Installed on : Sun Sep 7 13:30:57 PHT 2014 Origin : editors/vim Architectu...
I installed the Vim editor using Ports and in the process didn't enable GTK2 or GNOME option. I assume that either these 2 options will let me use gvim. Here's my pkg info vim: vim-7.4.430_1 Name : vim Version : 7.4.430_1 Installed on : Sun Sep 7 13:30:57 PHT 2014 Origin : editors/vim Architecture : freebsd:10:x86:32 Prefix : /usr/local Categories : editors Maintainer : sunpoet@FreeBSD.org WWW : http://www.vim.org/ Comment : Improved version of the vi editor Options : ATHENA : off CONSOLE : on CSCOPE : on EXUBERANT_CTAGS: on GNOME : off GTK2 : off LUA : on MOTIF : off NLS : on PERL : on PYTHON : on Now, I want to enable either the GNOME or GTK2 option. I've tried make deinstall followed by make reinstall but I don't get the dialogs for choosing the options to enable just like I did when I installed Vim the first time. I've also tried make deinstall then make install but still no go.
baktin (963 rep)
Sep 7, 2014, 05:41 AM • Last activity: Mar 16, 2021, 10:23 AM
1 votes
1 answers
1339 views
FreeBSD - delete a partially installed gnome2?
I've been trying to compile x11/gnome2 under FreeBSD 10.0-REL, but have been running into all sorts of issues. Eventually I found things indicating that gnome2 is no longer really supported, and that I should use something else (MATE, Xfce, KDE, whatever) instead. But gnome2 installs a trillion othe...
I've been trying to compile x11/gnome2 under FreeBSD 10.0-REL, but have been running into all sorts of issues. Eventually I found things indicating that gnome2 is no longer really supported, and that I should use something else (MATE, Xfce, KDE, whatever) instead. But gnome2 installs a trillion other packages, none of which I actually want if I'm not going to be using Gnome. So "make install" of gnome2 has failed, but not before installing a few billion packages that I don't want. I'd like to get rid of them before starting an install of Xfce or whatever. How can I easily delete those that aren't needed by anything that doesn't ultimately go back go the gnome2 package? So, in a perfect world I'd like a command that says: "Figure out all packages that are supposed to be installed via gnome2 (including recursively). For each such package, if it is installed, uninstall it *unless* there is some installed package that needs it and that is *not* among those installed via gnome2 (including recursively)." Is there an easy way to do this? Thanks in advance.
Bob Vesterman (277 rep)
Sep 29, 2014, 09:12 PM • Last activity: Mar 3, 2021, 12:10 AM
0 votes
2 answers
177 views
/usr/ports in OpenBSD
From the https://www.openbsd.org/faq/ports/ports.html. "The ports tree is meant for advanced users" .Who is 'advanced user' in OpenBSD world? Make file wizard, Port maintainer, core developer, Theo?
From the https://www.openbsd.org/faq/ports/ports.html . "The ports tree is meant for advanced users" .Who is 'advanced user' in OpenBSD world? Make file wizard, Port maintainer, core developer, Theo?
John John (1 rep)
Jan 23, 2021, 09:18 AM • Last activity: Jan 27, 2021, 02:27 PM
1 votes
1 answers
329 views
FreeBSD: How do I install port which doesn't show in searches?
I'd like to install version 6 of unifi network controller in a jail on my FreeNAS server. I can see that a `net-mgmt/unifi6` port exists in bugs.freebsd.org: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=249466. However I can't find it by searching any of the following places: - `/usr/ports` dir...
I'd like to install version 6 of unifi network controller in a jail on my FreeNAS server. I can see that a net-mgmt/unifi6 port exists in bugs.freebsd.org: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=249466 . However I can't find it by searching any of the following places: - /usr/ports directory - pkg search command - https://www.freebsd.org/ports/searching.html web page I'm guessing this is in a pre-release state. Is it possible to install? If so, how? Thanks!
zwiebelspaetzle (113 rep)
Sep 30, 2020, 07:36 PM • Last activity: Jan 11, 2021, 05:34 PM
0 votes
0 answers
56 views
FreeBSD packages on Linux distributions? Request for advices
When evaluating operating system for our next server, we have the following needs: 1. An OS with a stable version of Python3 so that machine codes compiled from C/C++/etc. sources from our `pip` packages won't have to change for an extended period of time seldomly updated. 2. A distribution that com...
When evaluating operating system for our next server, we have the following needs: 1. An OS with a stable version of Python3 so that machine codes compiled from C/C++/etc. sources from our pip packages won't have to change for an extended period of time seldomly updated. 2. A distribution that comes with latest version of PHP, and in particular PHP 7.4, so that we can invoke external Python and C programs without escaping the command string for the shell using the proc_open function. CentOS is excluded from consideration by 2, and Ubuntu by 1; The update cycle of Fedora is too volatile for most servers, including ours. For some people, whether for practical purposes or not, wants to have foreign packages on their system. One case in particular, would be using FreeBSD ports on Linux. I haven't tried it, but it should be theoretically possible. The point of this question is that: **Q**: I'd like some advice on some tricky areas, and in particular maintaining system integrity.
DannyNiu (692 rep)
Nov 18, 2020, 05:56 AM • Last activity: Nov 18, 2020, 06:32 AM
4 votes
1 answers
1459 views
FreeBSD ports: want to recompile everything, a few packages fail because "uninstall error" / "already installed"
Only used binary packages via `pkg install` for a long time. Then had to compile one package from source, since additional options had to be activated. Since that went so well, I wanted to switch completely to `/usr/ports` on this machine. Cleanup (got this from somewhere): ```` pkg autoremove ports...
Only used binary packages via pkg install for a long time. Then had to compile one package from source, since additional options had to be activated. Since that went so well, I wanted to switch completely to /usr/ports on this machine. Cleanup (got this from somewhere):
`
pkg autoremove
portsclean -C -D -DD
portsnap auto
portsclean -C -D -DD
` Then doing portupgrade -af --batch. This command results in:
`
** Listing the failed packages (-:ignored / *:skipped / !:failed)
        ! multimedia/libvpx (libvpx-1.9.0)      (uninstall error)
        ! databases/db5 (db5-5.3.28_7)  (uninstall error)
        * databases/ruby-bdb (ruby26-bdb-0.6.6_8)
        * ports-mgmt/portupgrade (portupgrade-2.4.16,2)
        * devel/apr1 (apr-1.7.0.1.6.1_1)
        [...]
` ... and then many more skipped packages.
`
root:/usr/ports/multimedia/libvpx # make install
===>  Installing for libvpx-1.9.0
===>  Checking if libvpx is already installed
===>   libvpx-1.9.0 is already installed
      You may wish to ``make deinstall'' and install this port again
      by ``make reinstall'' to upgrade it properly.
      If you really wish to overwrite the old port of libvpx
      without deleting it first, set the variable "FORCE_PKG_REGISTER"
      in your environment or the "make install" command line.
*** Error code 1

Stop.
make: stopped in /usr/ports/multimedia/libvpx
` Similar for databases/db5. So I do make deinstall and make reinstall in both directories and start portupgrade -af --batch again. But it ends with a similar message, which seems even worse; here just listing the lines with !:
! multimedia/libvpx (libvpx-1.9.0)      (uninstall error)
        ! databases/db5 (db5-5.3.28_7)  (uninstall error)
        ! devel/boost-libs (boost-libs-1.72.0_2)        (uninstall error)
        ! devel/cmake (cmake-3.18.3)    (uninstall error)
` So it is again the "uninstall error". What is the proper way to handle this? **Update:** It seems that Portupgrade is the culprit. It _does_ work fine with Portmaster. Namely:
`
env BATCH=yes portmaster -afGyd --no-confirm
` It took me a while to find out how convince this tool not to keep me busy pressing "y" and "Enter" every other minute, but then it worked through all my packages either with an "install", a "re-install", or an "upgrade". No errors. Then I tried portupgrade -af --batch once more, and it resulted in "uninstall error" again. I will write this up as an answer once I confirmed it by another run. **Update 2:** Another run with Portmaster yielded "uninstall error" for a few packages. Tried again on another day, after portsnap auto, and Portmaster worked through all my packages just fine. So the problem comes and goes. I'm giving up now. Since the last full run of Portmaster was successful, I will leave it at this. I installed a daily cron job:
`
#!/bin/sh
set -e
portsnap auto
env BATCH=yes portmaster -aGyd --no-confirm
env BATCH=yes portmaster -ys --no-confirm
service -R
echo "All done!"
` Hope this will be good. **Update 3:** I interleaved the above script with a couple more of env BATCH=yes portmaster -afGyd --no-confirm manually, which did not yield any errors, but indeed reinstalled all my packages. General remark: I will from now on always use ports on my FreeBSD installations. Precompiled packages via pkg work fine, but there will come a day when you need one tiny configuration in one tiny package to be set differently from the precompiled version. Then you need ports. Moreover, on that day, you will perhaps not have time to re-learn how to use essential parts of your operating system infrastructure. So I recommend to use ports all the way. Maybe check out Poudriere if having multiple machines (never tried it myself, but maybe will some day).
Lasse Kliemann (201 rep)
Oct 11, 2020, 10:00 AM • Last activity: Oct 21, 2020, 07:23 AM
3 votes
1 answers
4075 views
How to install portmaster on FreeBSD?
I'm trying to install portmaster on FreeBSD but I get an error about the port format: root@freebsd:/usr/ports/ports-mgmt/portmaster # make install clean ===> portmaster-3.17.8_1 pkg(8) must be version 1.6.0 or greater, but you have 1.4.12. You must upgrade the ports-mgmt/pkg port first. *** Error co...
I'm trying to install portmaster on FreeBSD but I get an error about the port format: root@freebsd:/usr/ports/ports-mgmt/portmaster # make install clean ===> portmaster-3.17.8_1 pkg(8) must be version 1.6.0 or greater, but you have 1.4.12. You must upgrade the ports-mgmt/pkg port first. *** Error code 1 Stop. make: stopped in /usr/ports/ports-mgmt/portmaster How can I upgrade the port file to the latest version?
ruipacheco (143 rep)
Dec 10, 2015, 10:24 PM • Last activity: Jun 17, 2020, 08:49 AM
0 votes
2 answers
282 views
What is the default ports tree in FreeBSD 12.1? Easiest way to change it?
[Starting with a fresh install of FreeBSD-12.1-RELEASE][1], when I run # portsnap fetch # portsnap extract does it extract the release branch, quarterly branch, HEAD or some other branch? Is there a config setting somewhere to change this or should I use subversion to track another ports tree? I'm f...
Starting with a fresh install of FreeBSD-12.1-RELEASE , when I run # portsnap fetch # portsnap extract does it extract the release branch, quarterly branch, HEAD or some other branch? Is there a config setting somewhere to change this or should I use subversion to track another ports tree? I'm fine using subversion, so I don't need a run down on that. Just wondering what the default is and if there's a simpler config to tweak and avoid it. Also, I understand that pkg uses the quarterly branch by default, but I'm not finding similar information on about ports.
Dave (3 rep)
May 23, 2020, 07:19 PM • Last activity: May 23, 2020, 09:06 PM
1 votes
2 answers
1604 views
Cross compile ports freebsd 11
I want to make cross compile environment for raspberrypi. Now I have VM with qemu-arm based cross compilation environment (based on [this][1] article), and it is VERY SLOW. I think that native i386 compiler can make executables for diffent arch, it needs only toolchain and properly configured make.c...
I want to make cross compile environment for raspberrypi. Now I have VM with qemu-arm based cross compilation environment (based on this article), and it is VERY SLOW. I think that native i386 compiler can make executables for diffent arch, it needs only toolchain and properly configured make.conf, but I can be wrong. Maybe someone know how to configure system for cross-building? - Host System: freebsd 11 on vm i386 - Target: freebsd 11 armv6hf Thanks for answers!
Consul (11 rep)
May 29, 2015, 05:40 PM • Last activity: May 20, 2020, 10:08 PM
6 votes
1 answers
1046 views
PC-BSD PBI, what reasons made it to be scrapped?
What are the detailed specific technical/organizational reasons that the PC-BSD team faced that ultimately lead them to scrap PBI and return to ports? Was because of the difficulties compiling and packing? Was because of problems with the hard links they created? Or because of the amount of work to...
What are the detailed specific technical/organizational reasons that the PC-BSD team faced that ultimately lead them to scrap PBI and return to ports? Was because of the difficulties compiling and packing? Was because of problems with the hard links they created? Or because of the amount of work to collect dependencies and compile together? I am curious just to know why the same team that create a software (say GNUCash ), take the time and effort to provide a self-contained version for Windows while the *NIX is left as to the compiler/installer. I am not asking about why ports and libraries are good (easy security upgrades,...). I also am not asking about preferences or opinions for packages vs Windows, just the technical reasons that led to scrap PBI. I am asking specifically why the route of PBI (0install, NixOS) is technically not feasible or broadly adopted.
null_pointer (123 rep)
Nov 19, 2015, 07:45 AM • Last activity: Dec 20, 2019, 05:21 PM
0 votes
2 answers
758 views
Using FreeBSD Ports & Packages, Installing Tomcat on FreeBSD 12 installs Java 8 rather than my already-installed Java 12
On FreeBSD 12, I already installed Java 12 successfully using: sudo pkg install openjdk12 And I edited `etc/fstab` as directed by the text emitted by that installer. Then I set the `PATH` to include the Java `bin` folder by editing my `.zshrc` with the line `path+=/usr/local/openjdk12/bin`. I verifi...
On FreeBSD 12, I already installed Java 12 successfully using: sudo pkg install openjdk12 And I edited etc/fstab as directed by the text emitted by that installer. Then I set the PATH to include the Java bin folder by editing my .zshrc with the line path+=/usr/local/openjdk12/bin. I verified that java --version works. Then I go to install Apache Tomcat 9. I checked with Ports to see there is an entry for the latest version , Tomcat 9.0.22. So I run: sudo pkg install tomcat9 I quickly notice this output during the installation: >[2/9] Fetching openjdk8-8.212.4.1.txz: 100% 80 MiB 83.4MB/s 00:01 Whoa, hold up there. I did not want the old OpenJDK 8 installed. I want Tomcat to be using that OpenJDK 12 I installed. ➥ How can I avoid installing OpenJDK 8, and instead direct the installer (if relevant) and Tomcat itself to use my OpenJDK 12?
Basil Bourque (1671 rep)
Jul 25, 2019, 07:51 PM • Last activity: Jul 31, 2019, 11:33 PM
1 votes
1 answers
1052 views
Installing Java on FreeBSD: `sudo pkg install openjdk11-11.0.4+11.1` fails to find package despite being listed in the "FreeBSD Ports Search" page
On the [*FreeBSD Ports Search*](https://www.freebsd.org/ports/index.html) page, I [see results listing][1] an item [`openjdk11-11.0.4+11.1`][2]. When I try to install that: $ sudo pkg install openjdk11-11.0.4+11.1 …I get error saying the package could not be found: >Updating FreeBSD repository catal...
On the [*FreeBSD Ports Search*](https://www.freebsd.org/ports/index.html) page, I see results listing an item openjdk11-11.0.4+11.1 . When I try to install that: $ sudo pkg install openjdk11-11.0.4+11.1 …I get error saying the package could not be found: >Updating FreeBSD repository catalogue... > >FreeBSD repository is up to date. > >All repositories are up to date. > >pkg: No packages available to install matching 'openjdk11-11.0.4+11.1' have been found in the repositories ➥ What am I missing here? What is the proper way to install Java/OpenJDK 11 or 12 on FreeBSD 12?
Basil Bourque (1671 rep)
Jul 23, 2019, 09:11 PM • Last activity: Jul 28, 2019, 06:52 AM
Showing page 1 of 20 total questions