ports-mgmt/portconf – not src.conf(5) – to specify multiple flavours of a port for buildkernel purposes

2023-08-21 Thread Graham Perrin

On 22/08/2023 05:34, Warner Losh wrote:


How might I use /etc/src.conf to achieve much the same, with a
different port?



I thought stuff like this went in ports.conf...

…


Warner solves another mystery. Thanks!

Honestly, I was oblivious to the possibility:

% man -P cat 5 ports.conf
No manual entry for ports.conf
% apropos ports.conf
apropos: nothing appropriate
% rg -i -e 'ports\.conf' /usr/doc/website/content/en
% rg -i -e 'ports\.conf' /usr/doc/documentation/content/en
%

– and so on. As far as I can tell, it's not documented in the usual places.

Eventually, Google helped to remind me of a 2021 comment 
, 
where part of the previous person's comment had never sunk in. I wrote:



(I never used ports-mgmt/portconf, and so on.)



So:


% gh repo sync grahamperrin/freebsd-ports && git -C /usr/ports pull 
--ff-only --quiet && git -C /usr/ports pull --ff-only freebsd main

✓Synced the "grahamperrin:main" branch from "freebsd:main"
Updating files: 100% (35/35), done.
From https://git.freebsd.org/ports
* branch  main   -> FETCH_HEAD
  15a5c70847f1..355374a1f6be  main   -> freebsd/main
Already up to date.
% sudo pkg install ports-mgmt/portconf
grahamperrin's password:
Updating FreeBSD repository catalogue...
FreeBSD repository is up to date.
Updating poudriere repository catalogue...
Fetching meta.conf: 100%    163 B   0.2kB/s    00:01
Fetching packagesite.pkg: 100%    2 KiB   2.2kB/s    00:01
The provides database is up-to-date.
Processing entries: 100%
poudriere repository update completed. 7 packages processed.
All repositories are up to date.
The following 1 package(s) will be affected (of 0 checked):

New packages to be INSTALLED:
   portconf: 1.6_1 [FreeBSD]

Number of packages to be installed: 1

2 KiB to be downloaded.

Proceed with this action? [y/N]: y
[1/1] Fetching portconf-1.6_1.pkg: 100%    2 KiB   2.3kB/s    00:01
Checking integrity... done (0 conflicting)
[1/1] Installing portconf-1.6_1...
[1/1] Extracting portconf-1.6_1: 100%
Spamming /etc/make.conf... Done.
=
Message from portconf-1.6_1:

--
To set port-specific make variables, create the
/usr/local/etc/ports.conf configuration file
with the following syntax:


# this is a comment
*: NOPORTDOCS
editors/openoffice-3: WITH_CCACHE|LOCALIZED_LANG=it
print/ghostscript-* print/lpr-wrapper: A4
sysutils/fusefs-kmod*: !KERNCONF | !NOPORTDOCS
www/firefox-i18n: WITHOUT_SWITCHER | FIREFOX_I18N=fr it
x11/fakeport: CONFIGURE_ARGS=--with-modules="aaa bbb ccc"


Global port directory patterns and blanks around the
pipe "|" symbol are allowed.
Values shouldn't be quoted even if they contain spaces.
Lines beginning with a '#' are comments.
% apropos ports.conf
apropos: nothing appropriate
% rg --count -e 'ports\.conf' /usr/ports
/usr/ports/net-mgmt/ocsinventory-ocsreports/files/pkg-message.in:1
/usr/ports/ports-mgmt/portconf/files/pkg-message.in:1
/usr/ports/ports-mgmt/portconf/files/portconf.sh.in:1
^C
% sudo nano /usr/local/etc/ports.conf
grahamperrin's password:
% cat /usr/local/etc/ports.conf
graphics/gpu-firmware-radeon-kmod: FLAVORS=btc sumo turks
%


Still, there's guesswork. I have /no/ idea whether the FLAVORS part of 
that last line is valid :-)


Time will tell.


Re: src.conf(5) to specify multiple flavours of a port

2023-08-21 Thread Bakul Shah
On Aug 21, 2023, at 9:24 PM, Graham Perrin  wrote:
> 
> In a thread elsewhere, as an example that did not involve src.conf, Mark 
> Johnston wrote: 
> 
>> $ cd /usr/ports/graphics/gpu-firmware-intel-kmod
>> $ sudo make reinstall FLAVOR=kabylake
> 
> How might I use /etc/src.conf to achieve much the same, with a different port?

Since /etc/src.conf is included from make, may be you can use some make feature
for conditional define? 


Re: src.conf(5) to specify multiple flavours of a port

2023-08-21 Thread Warner Losh
On Mon, Aug 21, 2023, 10:24 PM Graham Perrin  wrote:

> In a thread elsewhere, as an example that did *not* involve src.conf,
> Mark Johnston wrote:
>
> $ cd /usr/ports/graphics/gpu-firmware-intel-kmod
> $ sudo make reinstall FLAVOR=kabylake
>
>
> How might I use /etc/src.conf to achieve much the same, with a different
> port?
>


I thought stuff like this went in ports.conf...

Warner

> A recent edition of my file included these four lines, the third of which
> causes an error:
>
> PORTS_MODULES= graphics/drm-510-kmod
> # PORTS_MODULES= graphics/drm-515-kmod
> PORTS_MODULES+= graphics/gpu-firmware-radeon-kmod@btc
> graphics/gpu-firmware-radeon-kmod@sumo
> graphics/gpu-firmware-radeon-kmod@turks
> # PORTS_MODULES+= graphics/gpu-firmware-radeon-kmod
>
> This morning: I use the fourth line, instead.
>
> In future: I'd prefer to be without the build time that's associated with
> so many flavours, when only three are required.
>
> 
> 
>
>
> More than doubly time-consuming, because:
>
> KERNCONF=GENERIC GENERIC-NODEBUG
> # KERNCONF=GENERIC
> # KERNCONF=GENERIC-NODEBUG
>
> NO_INSTALLEXTRAKERNELS=no
>
> TIA
>
>
>


src.conf(5) to specify multiple flavours of a port

2023-08-21 Thread Graham Perrin
In a thread elsewhere, as an example that did /not/ involve src.conf, 
Mark Johnston wrote:



$ cd /usr/ports/graphics/gpu-firmware-intel-kmod
$ sudo make reinstall FLAVOR=kabylake


How might I use /etc/src.conf to achieve much the same, with a different 
port?


A recent edition of my file included these four lines, the third of 
which causes an error:


PORTS_MODULES= graphics/drm-510-kmod
# PORTS_MODULES= graphics/drm-515-kmod
PORTS_MODULES+= graphics/gpu-firmware-radeon-kmod@btc 
graphics/gpu-firmware-radeon-kmod@sumo 
graphics/gpu-firmware-radeon-kmod@turks

# PORTS_MODULES+= graphics/gpu-firmware-radeon-kmod

This morning: I use the fourth line, instead.

In future: I'd prefer to be without the build time that's associated 
with so many flavours, when only three are required.





More than doubly time-consuming, because:

KERNCONF=GENERIC GENERIC-NODEBUG
# KERNCONF=GENERIC
# KERNCONF=GENERIC-NODEBUG

NO_INSTALLEXTRAKERNELS=no

TIA



Re: Speed improvements in ZFS

2023-08-21 Thread Alexander Leidinger

Am 2023-08-21 10:53, schrieb Konstantin Belousov:

On Mon, Aug 21, 2023 at 08:19:28AM +0200, Alexander Leidinger wrote:

Am 2023-08-20 23:17, schrieb Konstantin Belousov:
> On Sun, Aug 20, 2023 at 11:07:08PM +0200, Mateusz Guzik wrote:
> > On 8/20/23, Alexander Leidinger  wrote:
> > > Am 2023-08-20 22:02, schrieb Mateusz Guzik:
> > >> On 8/20/23, Alexander Leidinger  wrote:
> > >>> Am 2023-08-20 19:10, schrieb Mateusz Guzik:
> >  On 8/18/23, Alexander Leidinger  wrote:
> > >>>
> > > I have a 51MB text file, compressed to about 1MB. Are you interested
> > > to
> > > get it?
> > >
> > 
> >  Your problem is not the vnode limit, but nullfs.
> > 
> >  https://people.freebsd.org/~mjg/netchild-periodic-find.svg
> > >>>
> > >>> 122 nullfs mounts on this system. And every jail I setup has several
> > >>> null mounts. One basesystem mounted into every jail, and then shared
> > >>> ports (packages/distfiles/ccache) across all of them.
> > >>>
> >  First, some of the contention is notorious VI_LOCK in order to do
> >  anything.
> > 
> >  But more importantly the mind-boggling off-cpu time comes from
> >  exclusive locking which should not be there to begin with -- as in
> >  that xlock in stat should be a slock.
> > 
> >  Maybe I'm going to look into it later.
> > >>>
> > >>> That would be fantastic.
> > >>>
> > >>
> > >> I did a quick test, things are shared locked as expected.
> > >>
> > >> However, I found the following:
> > >> if ((xmp->nullm_flags & NULLM_CACHE) != 0) {
> > >> mp->mnt_kern_flag |=
> > >> lowerrootvp->v_mount->mnt_kern_flag &
> > >> (MNTK_SHARED_WRITES | MNTK_LOOKUP_SHARED |
> > >> MNTK_EXTENDED_SHARED);
> > >> }
> > >>
> > >> are you using the "nocache" option? it has a side effect of xlocking
> > >
> > > I use noatime, noexec, nosuid, nfsv4acls. I do NOT use nocache.
> > >
> >
> > If you don't have "nocache" on null mounts, then I don't see how this
> > could happen.
>
> There is also MNTK_NULL_NOCACHE on lower fs, which is currently set for
> fuse and nfs at least.

11 of those 122 nullfs mounts are ZFS datasets which are also NFS 
exported.

6 of those nullfs mounts are also exported via Samba. The NFS exports
shouldn't be needed anymore, I will remove them.

By nfs I meant nfs client, not nfs exports.


No NFS client mounts anywhere on this system. So where is this exclusive 
lock coming from then...
This is a ZFS system. 2 pools: one for the root, one for anything I need 
space for. Both pools reside on the same disks. The root pool is a 3-way 
mirror, the "space-pool" is a 5-disk raidz2. All jails are on the 
space-pool. The jails are all basejail-style jails.


Bye,
Alexander.

--
http://www.Leidinger.net alexan...@leidinger.net: PGP 0x8F31830F9F2772BF
http://www.FreeBSD.orgnetch...@freebsd.org  : PGP 0x8F31830F9F2772BF



Re: kabylake + drm-515-kmod/drm-510-kmod hangs

2023-08-21 Thread Pete Wright




On 8/21/23 11:24, Mark Johnston wrote:


Does your system have the debug.debugger_on_panic sysctl set to 1?  If
so, does setting it to 0 allow the system to reboot following the hang?



oh fantastic, yea that works - thanks for the heads up!




Commit cedc82c0466a in src changed the layout of a structure used by a
stub in the GPU firmware kernel modules.  If you rebuild the one(s) you
need from ports, does the problem persist?

FWIW I had to do this:

$ cd /usr/ports/graphics/gpu-firmware-intel-kmod
$ sudo make reinstall FLAVOR=kabylake



bingo that was it.  i missed that change, thanks for pointing that out 
Mark.  I'm able to load the i915kms module now.


next step is figuring out why the nvidia-drm module is causing a panic 
(this is one of those funky intel + nvidia GPU laptops).  but i get a 
core on that, and having the intel gpu load allows me to run X at least.


thanks everyone!
-pete

--
Pete Wright
p...@nomadlogic.org
@nomadlogicLA



Re: kabylake + drm-515-kmod/drm-510-kmod hangs

2023-08-21 Thread Mark Johnston
On Mon, Aug 21, 2023 at 10:44:28AM -0700, Pete Wright wrote:
> hey there,
> i've got a kabylake laptop that i've been using with drm-kmod for several
> years without much hassle.  after upgrading to a new CURRENT this weekend
> I've found that when loading either the 510 or 515 drm-kmod kernel modules
> my system will hang.
> 
> unfortunately i am not getting a panic or crash, the screen stops updating
> and i am unable to ping or SSH into the system.  interestingly the capslock
> LED still toggles but doing a CTL+ALT+DEL does not seem to do anything
> useful and i have to manually power cycle.

Does your system have the debug.debugger_on_panic sysctl set to 1?  If
so, does setting it to 0 allow the system to reboot following the hang?

> any tips for finding out what's going on?  i've booted the system with
> verbose dmesg output, and loaded the module with "kldload -v" but do not get
> any useful output.

Commit cedc82c0466a in src changed the layout of a structure used by a
stub in the GPU firmware kernel modules.  If you rebuild the one(s) you
need from ports, does the problem persist?

FWIW I had to do this:

$ cd /usr/ports/graphics/gpu-firmware-intel-kmod
$ sudo make reinstall FLAVOR=kabylake



Re: kabylake + drm-515-kmod/drm-510-kmod hangs

2023-08-21 Thread Pete Wright




On 8/21/23 10:49, Poul-Henning Kamp wrote:


Pete Wright writes:


i've got a kabylake laptop that i've been using with drm-kmod for
several years without much hassle.  after upgrading to a new CURRENT
this weekend I've found that when loading either the 510 or 515 drm-kmod
kernel modules my system will hang.


Does it make any difference if you load the module from single-user mode ?

I've seen similar problems on my T14s if I try to load it from multi-user.



oh that's an interesting idea.  i just tried it and unfortunately got 
the same results.


-pete

--
Pete Wright
p...@nomadlogic.org
@nomadlogicLA



Re: kabylake + drm-515-kmod/drm-510-kmod hangs

2023-08-21 Thread Pete Wright




On 8/21/23 10:53, Cy Schubert wrote:

In message <76275772-a9c3-ed59-5fb3-47a13d2a6...@nomadlogic.org>, Pete
Wright w
rites:

hey there,
i've got a kabylake laptop that i've been using with drm-kmod for
several years without much hassle.  after upgrading to a new CURRENT
this weekend I've found that when loading either the 510 or 515 drm-kmod
kernel modules my system will hang.

unfortunately i am not getting a panic or crash, the screen stops
updating and i am unable to ping or SSH into the system.  interestingly
the capslock LED still toggles but doing a CTL+ALT+DEL does not seem to
do anything useful and i have to manually power cycle.

any tips for finding out what's going on?  i've booted the system with
verbose dmesg output, and loaded the module with "kldload -v" but do not
get any useful output.

here's the uname:
FreeBSD colony 14.0-ALPHA2 FreeBSD 14.0-ALPHA2 amd64 1400096 #0
main-n264924-e2340276fc73: Sun Aug 20 21:28:44 PDT 2023
pete@colony:/usr/obj/usr/home/pete/git/freebsd/amd64.amd64/sys/GENERIC amd64


these are the log messages i see before the system locks up:
Aug 21 10:40:34 colony kernel: iic0:  on iicbus0
Aug 21 10:40:35 colony kernel: drmn0:  on vgapci0
Aug 21 10:40:35 colony kernel: vgapci0: child drmn0 requested pci_enable_io
Aug 21 10:40:35 colony syslogd: last message repeated 1 times
Aug 21 10:40:35 colony kernel: [drm] Unable to create a private tmpfs
mount, hugepage support will be disabled(-19).
Aug 21 10:40:35 colony kernel: [drm] Got stolen memory base 0x4b80,
size 0x400
Aug 21 10:40:35 colony kernel: lkpi_iic0:  on drmn0
Aug 21 10:40:35 colony kernel: iicbus1:  on lkpi_iic0
Aug 21 10:40:35 colony kernel: iic1:  on iicbus1
Aug 21 10:40:35 colony kernel: lkpi_iic1:  on drmn0
Aug 21 10:40:35 colony kernel: iicbus2:  on lkpi_iic1
Aug 21 10:40:35 colony kernel: iic2:  on iicbus2
Aug 21 10:40:35 colony kernel: lkpi_iic2:  on drmn0
Aug 21 10:40:35 colony kernel: iicbus3:  on lkpi_iic2
Aug 21 10:40:35 colony kernel: iic3:  on iicbus3
Aug 21 10:40:35 colony kernel: lkpi_iic3:  on drmn0
Aug 21 10:40:35 colony kernel: iicbus4:  on lkpi_iic3
Aug 21 10:40:35 colony kernel: iic4:  on iicbus4



cheers,
-pete

--
Pete Wright
p...@nomadlogic.org
@nomadlogicLA



Rebuilding drm-51[05]-kmod after an update to LinuxKPI affecting the ABI
used by the drm modules is required. Typically I get a kernel panic on a
page fault when this occurs. Depending on how memory is laid out on your
system you may get a hang instead.

You need to install thew new kernel and world first. Disable xdm, gdm, any
other *dm, or simply not use startx. From a text console session rebuild
the drm port and reinstall it.

I use poudriere here. My procedure is to update the poudriere jail, rebuild
the port (-C option) and pkg upgrade -f or pkg install -f. Use this
approach if you use poudriere.




Thanks Cy, yes my local scripts ensure to update the ports tree, then 
rebuild the drm-kmod module i'm using as a package.  then i remove the 
old pkg, install the freshly build one then reboot.  this ensures my 
kernel and drm modules match.


this is how i've been doing it for years on all my systems since we 
started the work on the drm-kmod.



-pete


--
Pete Wright
p...@nomadlogic.org
@nomadlogicLA



Re: kabylake + drm-515-kmod/drm-510-kmod hangs

2023-08-21 Thread Cy Schubert
In message <76275772-a9c3-ed59-5fb3-47a13d2a6...@nomadlogic.org>, Pete 
Wright w
rites:
> hey there,
> i've got a kabylake laptop that i've been using with drm-kmod for 
> several years without much hassle.  after upgrading to a new CURRENT 
> this weekend I've found that when loading either the 510 or 515 drm-kmod 
> kernel modules my system will hang.
>
> unfortunately i am not getting a panic or crash, the screen stops 
> updating and i am unable to ping or SSH into the system.  interestingly 
> the capslock LED still toggles but doing a CTL+ALT+DEL does not seem to 
> do anything useful and i have to manually power cycle.
>
> any tips for finding out what's going on?  i've booted the system with 
> verbose dmesg output, and loaded the module with "kldload -v" but do not 
> get any useful output.
>
> here's the uname:
> FreeBSD colony 14.0-ALPHA2 FreeBSD 14.0-ALPHA2 amd64 1400096 #0 
> main-n264924-e2340276fc73: Sun Aug 20 21:28:44 PDT 2023 
> pete@colony:/usr/obj/usr/home/pete/git/freebsd/amd64.amd64/sys/GENERIC amd64
>
>
> these are the log messages i see before the system locks up:
> Aug 21 10:40:34 colony kernel: iic0:  on iicbus0
> Aug 21 10:40:35 colony kernel: drmn0:  on vgapci0
> Aug 21 10:40:35 colony kernel: vgapci0: child drmn0 requested pci_enable_io
> Aug 21 10:40:35 colony syslogd: last message repeated 1 times
> Aug 21 10:40:35 colony kernel: [drm] Unable to create a private tmpfs 
> mount, hugepage support will be disabled(-19).
> Aug 21 10:40:35 colony kernel: [drm] Got stolen memory base 0x4b80, 
> size 0x400
> Aug 21 10:40:35 colony kernel: lkpi_iic0:  on drmn0
> Aug 21 10:40:35 colony kernel: iicbus1:  on lkpi_iic0
> Aug 21 10:40:35 colony kernel: iic1:  on iicbus1
> Aug 21 10:40:35 colony kernel: lkpi_iic1:  on drmn0
> Aug 21 10:40:35 colony kernel: iicbus2:  on lkpi_iic1
> Aug 21 10:40:35 colony kernel: iic2:  on iicbus2
> Aug 21 10:40:35 colony kernel: lkpi_iic2:  on drmn0
> Aug 21 10:40:35 colony kernel: iicbus3:  on lkpi_iic2
> Aug 21 10:40:35 colony kernel: iic3:  on iicbus3
> Aug 21 10:40:35 colony kernel: lkpi_iic3:  on drmn0
> Aug 21 10:40:35 colony kernel: iicbus4:  on lkpi_iic3
> Aug 21 10:40:35 colony kernel: iic4:  on iicbus4
>
>
>
> cheers,
> -pete
>
> -- 
> Pete Wright
> p...@nomadlogic.org
> @nomadlogicLA
>

Rebuilding drm-51[05]-kmod after an update to LinuxKPI affecting the ABI 
used by the drm modules is required. Typically I get a kernel panic on a 
page fault when this occurs. Depending on how memory is laid out on your 
system you may get a hang instead.

You need to install thew new kernel and world first. Disable xdm, gdm, any 
other *dm, or simply not use startx. From a text console session rebuild 
the drm port and reinstall it.

I use poudriere here. My procedure is to update the poudriere jail, rebuild 
the port (-C option) and pkg upgrade -f or pkg install -f. Use this 
approach if you use poudriere.


-- 
Cheers,
Cy Schubert 
FreeBSD UNIX: Web:  https://FreeBSD.org
NTP:   Web:  https://nwtime.org

e^(i*pi)+1=0






Re: kabylake + drm-515-kmod/drm-510-kmod hangs

2023-08-21 Thread Poul-Henning Kamp

Pete Wright writes:

> i've got a kabylake laptop that i've been using with drm-kmod for 
> several years without much hassle.  after upgrading to a new CURRENT 
> this weekend I've found that when loading either the 510 or 515 drm-kmod 
> kernel modules my system will hang.

Does it make any difference if you load the module from single-user mode ?

I've seen similar problems on my T14s if I try to load it from multi-user.

-- 
Poul-Henning Kamp   | UNIX since Zilog Zeus 3.20
p...@freebsd.org | TCP/IP since RFC 956
FreeBSD committer   | BSD since 4.3-tahoe
Never attribute to malice what can adequately be explained by incompetence.



kabylake + drm-515-kmod/drm-510-kmod hangs

2023-08-21 Thread Pete Wright

hey there,
i've got a kabylake laptop that i've been using with drm-kmod for 
several years without much hassle.  after upgrading to a new CURRENT 
this weekend I've found that when loading either the 510 or 515 drm-kmod 
kernel modules my system will hang.


unfortunately i am not getting a panic or crash, the screen stops 
updating and i am unable to ping or SSH into the system.  interestingly 
the capslock LED still toggles but doing a CTL+ALT+DEL does not seem to 
do anything useful and i have to manually power cycle.


any tips for finding out what's going on?  i've booted the system with 
verbose dmesg output, and loaded the module with "kldload -v" but do not 
get any useful output.


here's the uname:
FreeBSD colony 14.0-ALPHA2 FreeBSD 14.0-ALPHA2 amd64 1400096 #0 
main-n264924-e2340276fc73: Sun Aug 20 21:28:44 PDT 2023 
pete@colony:/usr/obj/usr/home/pete/git/freebsd/amd64.amd64/sys/GENERIC amd64



these are the log messages i see before the system locks up:
Aug 21 10:40:34 colony kernel: iic0:  on iicbus0
Aug 21 10:40:35 colony kernel: drmn0:  on vgapci0
Aug 21 10:40:35 colony kernel: vgapci0: child drmn0 requested pci_enable_io
Aug 21 10:40:35 colony syslogd: last message repeated 1 times
Aug 21 10:40:35 colony kernel: [drm] Unable to create a private tmpfs 
mount, hugepage support will be disabled(-19).
Aug 21 10:40:35 colony kernel: [drm] Got stolen memory base 0x4b80, 
size 0x400

Aug 21 10:40:35 colony kernel: lkpi_iic0:  on drmn0
Aug 21 10:40:35 colony kernel: iicbus1:  on lkpi_iic0
Aug 21 10:40:35 colony kernel: iic1:  on iicbus1
Aug 21 10:40:35 colony kernel: lkpi_iic1:  on drmn0
Aug 21 10:40:35 colony kernel: iicbus2:  on lkpi_iic1
Aug 21 10:40:35 colony kernel: iic2:  on iicbus2
Aug 21 10:40:35 colony kernel: lkpi_iic2:  on drmn0
Aug 21 10:40:35 colony kernel: iicbus3:  on lkpi_iic2
Aug 21 10:40:35 colony kernel: iic3:  on iicbus3
Aug 21 10:40:35 colony kernel: lkpi_iic3:  on drmn0
Aug 21 10:40:35 colony kernel: iicbus4:  on lkpi_iic3
Aug 21 10:40:35 colony kernel: iic4:  on iicbus4



cheers,
-pete

--
Pete Wright
p...@nomadlogic.org
@nomadlogicLA



Question about KBI change / new feature

2023-08-21 Thread Zhenlei Huang
Hi,

The https://www.freebsd.org/releases/14.0R/schedule/ says CURRENT/14 's KBI is 
froze
and new features should be avoided.

I'm working on https://reviews.freebsd.org/D39638 (sysctl(9): Enable vnet 
sysctl variables be loader tunable)
and I think it is new feature, but not quite sure whether the KBI changed.

So,

1. Is it a KBI change ?

2. It is a simple change ( while so far as I know currently only tested by 
myself on x86 and qemu riscv ), can
it catch up with 14 ?


Best regards,
Zhenlei




Re: Announce /etc/rc.d/sendmail does not work in default should be made at use time.

2023-08-21 Thread Christoph Moench-Tegeder
## KIRIYAMA Kazuhiko (k...@truefc.org):

> But there are nothing pointers to be changed default MTA
> changed to dma from sendmail ;-(

There is: UPDATING 20221205.

Regards,
Christoph

-- 
Spare Space



Re: Speed improvements in ZFS

2023-08-21 Thread Konstantin Belousov
On Mon, Aug 21, 2023 at 08:19:28AM +0200, Alexander Leidinger wrote:
> Am 2023-08-20 23:17, schrieb Konstantin Belousov:
> > On Sun, Aug 20, 2023 at 11:07:08PM +0200, Mateusz Guzik wrote:
> > > On 8/20/23, Alexander Leidinger  wrote:
> > > > Am 2023-08-20 22:02, schrieb Mateusz Guzik:
> > > >> On 8/20/23, Alexander Leidinger  wrote:
> > > >>> Am 2023-08-20 19:10, schrieb Mateusz Guzik:
> > >  On 8/18/23, Alexander Leidinger  wrote:
> > > >>>
> > > > I have a 51MB text file, compressed to about 1MB. Are you interested
> > > > to
> > > > get it?
> > > >
> > > 
> > >  Your problem is not the vnode limit, but nullfs.
> > > 
> > >  https://people.freebsd.org/~mjg/netchild-periodic-find.svg
> > > >>>
> > > >>> 122 nullfs mounts on this system. And every jail I setup has several
> > > >>> null mounts. One basesystem mounted into every jail, and then shared
> > > >>> ports (packages/distfiles/ccache) across all of them.
> > > >>>
> > >  First, some of the contention is notorious VI_LOCK in order to do
> > >  anything.
> > > 
> > >  But more importantly the mind-boggling off-cpu time comes from
> > >  exclusive locking which should not be there to begin with -- as in
> > >  that xlock in stat should be a slock.
> > > 
> > >  Maybe I'm going to look into it later.
> > > >>>
> > > >>> That would be fantastic.
> > > >>>
> > > >>
> > > >> I did a quick test, things are shared locked as expected.
> > > >>
> > > >> However, I found the following:
> > > >> if ((xmp->nullm_flags & NULLM_CACHE) != 0) {
> > > >> mp->mnt_kern_flag |=
> > > >> lowerrootvp->v_mount->mnt_kern_flag &
> > > >> (MNTK_SHARED_WRITES | MNTK_LOOKUP_SHARED |
> > > >> MNTK_EXTENDED_SHARED);
> > > >> }
> > > >>
> > > >> are you using the "nocache" option? it has a side effect of xlocking
> > > >
> > > > I use noatime, noexec, nosuid, nfsv4acls. I do NOT use nocache.
> > > >
> > > 
> > > If you don't have "nocache" on null mounts, then I don't see how this
> > > could happen.
> > 
> > There is also MNTK_NULL_NOCACHE on lower fs, which is currently set for
> > fuse and nfs at least.
> 
> 11 of those 122 nullfs mounts are ZFS datasets which are also NFS exported.
> 6 of those nullfs mounts are also exported via Samba. The NFS exports
> shouldn't be needed anymore, I will remove them.
By nfs I meant nfs client, not nfs exports.

> 
> Shouldn't this implicit nocache propagate to the mount of the upper fs to
> give the user feedback about the effective state?
> 
> Bye,
> Alexander.
> 
> -- 
> http://www.Leidinger.net alexan...@leidinger.net: PGP 0x8F31830F9F2772BF
> http://www.FreeBSD.orgnetch...@freebsd.org  : PGP 0x8F31830F9F2772BF



Announce /etc/rc.d/sendmail does not work in default should be made at use time.

2023-08-21 Thread KIRIYAMA Kazuhiko
Hi, all

I found /etc/rc.d/sendmail does not work in default. To make
use of sendmail, I had to be done with
`cp /usr/share/examples/sendmail/mailer.conf /etc/mail'.

I saw why default MTA changed to dma:

commit a67b925ff3e58b072a60b633e442ee1d33e47f7f
Author: Baptiste Daroussin 
Date:   Thu Oct 13 11:37:21 2022 +0200

mail: make The Dragonfly Mail Agent (dma) the default mta.

dma accepts mail from a local Mail User Agent (MUA) and delivers it
locally or to a smarthost for delivery. dma does not accept inbound
mail (i.e., it does not listen on port 25) and is not intended to
provide the same functionality as a full MTA like postfix or 
sendmail.
It is intended for use cases such as delivering cron(8) mail. which
is the default configuration and usage of sendmail in the default
setup of the base system.

In order to switch the default from sendmail to dma, we teach
mailwrapper to fallback on dma directly if the mailer.conf file 
cannot
be opened.
We install by default a mailer.conf file which points at dma
We install a mailer.conf file for sendmail in the examples.

Relnotes:   yes
Differential Revision:  https://reviews.freebsd.org/D37035

But there are nothing pointers to be changed default MTA
changed to dma from sendmail ;-(  Especially people who
daily use sendmail with `service sendmail start', 
"Starting sendmail" message was shown but nothing done ;-)

There should be announced that default MTA is dma when
sendmail start ?

---
Kazuhiko Kiriyama



Re: Speed improvements in ZFS

2023-08-21 Thread Alexander Leidinger

Am 2023-08-20 23:17, schrieb Konstantin Belousov:

On Sun, Aug 20, 2023 at 11:07:08PM +0200, Mateusz Guzik wrote:

On 8/20/23, Alexander Leidinger  wrote:
> Am 2023-08-20 22:02, schrieb Mateusz Guzik:
>> On 8/20/23, Alexander Leidinger  wrote:
>>> Am 2023-08-20 19:10, schrieb Mateusz Guzik:
 On 8/18/23, Alexander Leidinger  wrote:
>>>
> I have a 51MB text file, compressed to about 1MB. Are you interested
> to
> get it?
>

 Your problem is not the vnode limit, but nullfs.

 https://people.freebsd.org/~mjg/netchild-periodic-find.svg
>>>
>>> 122 nullfs mounts on this system. And every jail I setup has several
>>> null mounts. One basesystem mounted into every jail, and then shared
>>> ports (packages/distfiles/ccache) across all of them.
>>>
 First, some of the contention is notorious VI_LOCK in order to do
 anything.

 But more importantly the mind-boggling off-cpu time comes from
 exclusive locking which should not be there to begin with -- as in
 that xlock in stat should be a slock.

 Maybe I'm going to look into it later.
>>>
>>> That would be fantastic.
>>>
>>
>> I did a quick test, things are shared locked as expected.
>>
>> However, I found the following:
>> if ((xmp->nullm_flags & NULLM_CACHE) != 0) {
>> mp->mnt_kern_flag |=
>> lowerrootvp->v_mount->mnt_kern_flag &
>> (MNTK_SHARED_WRITES | MNTK_LOOKUP_SHARED |
>> MNTK_EXTENDED_SHARED);
>> }
>>
>> are you using the "nocache" option? it has a side effect of xlocking
>
> I use noatime, noexec, nosuid, nfsv4acls. I do NOT use nocache.
>

If you don't have "nocache" on null mounts, then I don't see how this
could happen.


There is also MNTK_NULL_NOCACHE on lower fs, which is currently set for
fuse and nfs at least.


11 of those 122 nullfs mounts are ZFS datasets which are also NFS 
exported. 6 of those nullfs mounts are also exported via Samba. The NFS 
exports shouldn't be needed anymore, I will remove them.


Shouldn't this implicit nocache propagate to the mount of the upper fs 
to give the user feedback about the effective state?


Bye,
Alexander.

--
http://www.Leidinger.net alexan...@leidinger.net: PGP 0x8F31830F9F2772BF
http://www.FreeBSD.orgnetch...@freebsd.org  : PGP 0x8F31830F9F2772BF