# I want to install FreeBSD alongside Linux.



## judd (Sep 10, 2020)

I want to install on my Ultrabox Dell inspiron 5423 14z, FreeBSD 12.1 with ZFS next to Pacbang Linux (Arch), which I have had for quite some time and do not wish to uninstall it.

These are my current partitions:


```
$ lsblk -lfm
NAME FSTYPE FSVER LABEL UUID                                 FSAVAIL FSUSE% MOUNTPOINT   SIZE OWNER GROUP   MODE
sda 465,8G root disk brw-rw----
sda1 xfs  398,9G 14% /home 465,8G root disk brw-rw----
sdb 29,8G root disk brw-rw----
sdb1 vfat FAT32  510,7M 0% /boot/efi 512M root disk brw-rw----
sdb2 ext4 1.0  14G 46% / 29,3G root disk brw-rw----
sr0 1024M root optical brw-rw----
```


```
$ df -hT
S.ficheros     Tipo     Tamaño Usados  Disp Uso% Montado en
dev devtmpfs 3,9G 0 3,9G 0% /dev
run tmpfs 3,9G 1,3M 3,9G 1% /run
/dev/sdb2 ext4 29G 14G 15G 49% /
tmpfs tmpfs 3,9G 0 3,9G 0% /dev/shm
tmpfs tmpfs 4,0M 0 4,0M 0% /sys/fs/cgroup
tmpfs tmpfs 3,9G 16K 3,9G 1% /tmp
/dev/sdb1 vfat 511M 256K 511M 1% /boot/efi
/dev/sda1 xfs 466G 67G 399G 15% /home
tmpfs tmpfs 783M 84K 783M 1% /run/user/1000
```

This machine has 2 disks, as shown in the result of the above parameter:
One 32 gigabyte SSD boot disk. → /boot + /root
Second 500 gigas HDD. → /home


```
$ inxi -Fxxx0
System:    Host: arch Kernel: 5.8.7.a-1-hardened x86_64 bits: 64 compiler: N/A Desktop: KDE Plasma 5.19.5 tk: Qt 5.15.0
           wm: kwin_x11 dm: startx Distro: PacBang Linux
Machine:   Type: Portable System: Dell product: Inspiron 5423 v: N/A serial: <superuser/root required> Chassis: type: 8
           serial: <superuser/root required>
           Mobo: Dell model: 0H4MCJ v: A08  UEFI: Dell v: A08 date: 11/26/2012
Battery:   ID-1: BAT0 charge: 1.8 Wh condition: 31.8/44.4 Wh (72%) volts: 11.5/11.1 model: SMP-SDI2.0 DELL 8JVDG27
           type: Li-ion serial: 1154 status: Charging
CPU:       Info: Dual Core model: Intel Core i7-3517U bits: 64 type: MT MCP arch: Ivy Bridge rev: 9 L2 cache: 4096 KiB
           flags: avx lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx bogomips: 15169
           Speed: 798 MHz min/max: 800/3000 MHz Core speeds (MHz): 1: 798 2: 798 3: 798 4: 798
Graphics:  Device-1: Intel 3rd Gen Core processor Graphics vendor: Dell driver: i915 v: kernel bus ID: 00:02.0
           chip ID: 8086:0166
           Device-2: Advanced Micro Devices [AMD/ATI] Thames [Radeon HD 7550M/7570M/7650M] vendor: Dell driver: radeon
           v: kernel bus ID: 02:00.0 chip ID: 1002:6841
           Device-3: Sunplus Innovation type: USB driver: uvcvideo bus ID: 1-1.5:5 chip ID: 1bcf:2982
           Display: server: X.Org 1.20.9 compositor: kwin_x11 driver: ati,intel,radeon unloaded: fbdev,modesetting,vesa
           resolution: 1366x768~60Hz s-dpi: 96
           OpenGL: renderer: Mesa DRI Intel HD Graphics 4000 (IVB GT2) v: 4.2 Mesa 20.1.7 compat-v: 3.0 direct render: Yes
Audio:     Device-1: Intel 7 Series/C216 Family High Definition Audio vendor: Dell driver: snd_hda_intel v: kernel
           bus ID: 00:1b.0 chip ID: 8086:1e20
           Sound Server: ALSA v: k5.8.7.a-1-hardened
Network:   Device-1: Broadcom and subsidiaries BCM43142 802.11b/g/n vendor: Dell Wireless 1704 802.11n + BT 4.0 driver: wl
           v: kernel port: e000 bus ID: 07:00.0 chip ID: 14e4:4365
           IF: wlp7s0 state: up mac: 08:ed:b9:92:d0:23
           Device-2: Qualcomm Atheros AR8162 Fast Ethernet vendor: Dell driver: alx v: kernel port: d000 bus ID: 09:00.0
           chip ID: 1969:1090
           IF: enp9s0 state: down mac: 78:45:c4:bc:b7:8a
           IF-ID-1: wg0 state: unknown speed: N/A duplex: N/A mac: N/A
Drives:    Local Storage: total: 495.58 GiB used: 79.90 GiB (16.1%)
           ID-1: /dev/sda vendor: Western Digital model: WD5000LPVT-75G33T0 size: 465.76 GiB speed: 3.0 Gb/s
           rotation: 5400 rpm  rev: 1A01 scheme: GPT
           ID-2: /dev/sdb vendor: Micron model: C400 RealSSD mSATA 32GB size: 29.82 GiB speed: 6.0 Gb/s
           rev: 01MG scheme: GPT
RAID:      Hardware-1: Intel 82801 Mobile SATA Controller [RAID mode] driver: ahci v: 3.0 port: f060 bus ID: 00:1f.2
           chip ID: 8086.282a rev: 04
Partition: ID-1: / size: 28.73 GiB used: 13.23 GiB (46.0%) fs: ext4 dev: /dev/sdb2
           ID-2: /home size: 465.53 GiB used: 66.67 GiB (14.3%) fs: xfs dev: /dev/sda1
Swap:      Alert: No Swap data was found.
Sensors:   System Temperatures: cpu: 47.0 C mobo: 45.0 C gpu: radeon temp: 45.5 C
           Fan Speeds (RPM): cpu: 0
Info:      Processes: 205 Uptime: 4m Memory: 7.64 GiB used: 915.4 MiB (11.7%) Init: systemd v: 246 target: graphical.target
           Compilers: gcc: 10.2.0 Packages: pacman: 1525 Shell: Bash v: 5.0.18 running in: konsole inxi: 3.1.06
```

I haven't done any partitioning yet.
To be noted:

1) Obviously what worries me most is the partitioning of the first 32 GB boot disk ?

2) The other 500 GB disk being /home, I don't find that problematic ?

I hope I can achieve this with your help.

Thank you as always!


----------



## chrbr (Sep 10, 2020)

I would keep the SSD for Linux as it is and add a FreeBSD partition on the HDD plus one small FreeBSD swap partition. Then you can select the boot system from the boot menu of the bios or use the Linux boot manager to select Linux or FreeBSD.


judd said:


> RAID: Hardware-1: Intel 82801 Mobile SATA Controller [RAID mode] driver: ahci v: 3.0 port: f060 bus ID: 00:1f.2 chip ID: 8086.282a rev: 04


I am not sure what RAID mode means here and if it can interfer with ZFS. Please check that or wait for additional answers. 


judd said:


> Network: Device-1: Broadcom and subsidiaries BCM43142 802.11b/g/n vendor: Dell Wireless 1704 802.11n + BT 4.0 driver: wl v: kernel port: e000 bus ID: 07:00.0 chip ID: 14e4:4365


I am not sure if the chip is supported. Please see https://www.freebsd.org/releases/12.1R/hardware.html#wlan. BCM43XX are listed but BCM43XXX not. Dell Wireless 1470 is supported but Dell Wireless 1704 is not listed. You can try with booting for the installer and check the Broadcom driver. As far as I know 802.11n is not yet supported. But for normal use the internet servers are the bottle neck and not the home LAN.
Basically the system looks nice and I am sure that you will enjoy FreeBSD running on that machine.


----------



## T-Daemon (Sep 10, 2020)

I would recommend the same as *chrbr *has, I wouldn't touch the small disk, I would backup /home from the big disk, install FreeBSD root-on-ZFS on it ( with a modified installer, which lets you choose the size of the zroot partition ), recreate Pacbang Linux /home partition.

Installing both OS's on the small disc side by side would complicates the situation It would mean manual intervention because the ZFS installer doesn't let you choose on which part of the disk to install, not only that, it would wipe Linux. Installing on two disks has also the advantage to boot the OS's from the laptops boot menu as *chrbr* already mentioned.

A warning, there is always a risk losing data in such a attempt, before beginning the project make a few backups of the data you don't want to lose, at least two. You should also make a backup of the Linux root partition, in case something goes wrong you can restore easily. gparted can create an .img of the whole partition in a GUI environment, unless you prefer dd(1).


----------



## Mjölnir (Sep 10, 2020)

Have a look at the Dual Boot Howto & the Labeling partitions done right on modern computers.
Don't name all your zpools _zroot, zpool, pool_ or such, but give distinctive names so you know which is what & on which disk it lives...
I would backup that /home disk and reformat from XFS to ZFS, since that's superior & both OS can access that.  Unless you want to use the brand new OpenZFS (from ports), let FreeBSD create the zpool(8) & do not allow Linux to upgrade the _zpool_'s version.
I guess you have to manually insert a `zpool export` into each OS's shutdown script: create a /etc/shutdown.local script, it will be sourced _automagically_ by /etc/rc.d/local @shutdown, i.e. you can ommit the _shebang_ comment.
Strongly consider to add a swap partition to the SSD.  Unfortunately, there is no priority machanism for swap in FreeBSD...  Having a dedicated swap partition (min. 4 GB, better 8) improves performance, since it gives more freedom to the VM system. IIRC swap can be shared between Linux & FreeBSD, but requires some tweaks? That would mean you have to shrink the Linux ext4(5) root filesystem (sysutils/e2fsprogs: resize2fs(8)) & add the swap partition.  FreeBSD can swap to a ZVOL (optionally you can set `volblocksize=4K`, `compression=off` & `dedup=off`).
If you want suspend-to-disk (aka _hibernation_), you need a special IRST partition of the size of your RAM.  I don't know if that can be on another disk you didn't boot from, you have to try (and post here or on that thread about success or failure).
Obviously you would have to shrink the Linux root partition on the 2nd disk (/dev/sdb) to make room for FreeBSD, and then you're left with ~10-14 GB for each, which is very small for today's demands (lower bound if you add a swap partition).  A few snapshots, and you'll run out of space.  Thus I would suggest to install FreeBSD on the 1st HDD (/dev/sda), and do not have a separate partition for /home, but let that be a dataset as usual and mount only that under Linux.  Having a separate partition for /home would give up one of the main advantages of ZFS: integrating volume management (i.e. your FreeBSD partition's size is restricted).  Since you want to share that _zpool_ between Linux & FreeBSD, you would need to set most datasets property `canmount=off` and instead mount them from fstab(5), except for the /home dataset.
Alternatively, consider to invest a few bucks & buy a larger SSD.  You can grep the SSD's lifetime from `smartctl -t short`, wait 2 minutes, then `smartctl -l selftest`.  Note that it wraps after ~7 1/2 years -- so maybe you have to guess.  That old SSD may still serve as ZFS cache or such, so you can sell it to a tinkerer.  Beeing at it: depending on your workload, consider to place a partition for ZFS cache for the rotating HDD on the SSD.


----------



## drhowarddrfine (Sep 10, 2020)

T-Daemon said:


> A warning, there is always a risk loosing data in such a attempt, before beginning the project make a few backups of the data you don't want to loose, at least two.


Losing is spelled l-o-s-i-n-g. Lose is spelled l-o-s-e.

Why do I see this spelling error all over the internet lately?


----------



## T-Daemon (Sep 10, 2020)

drhowarddrfine said:


> Losing is spelled l-o-s-i-n-g. Lose is spelled l-o-s-e.
> 
> Why do I see this spelling error all over the internet lately?



I can't speak for others, but I made the mistake because of the pronunciation, and ignoring there might be a similar word with a different meaning:

lose : looz
loose : loos

Thanks for making me aware. Corrected. Investigated matter:


```
lose | luːz |
verb (past and past participle lost | lɒst | ) [with object]

1 be deprived of or cease to have or retain (something)
```


```
loose | luːs |
adjective

1 not firmly or tightly fixed in place; detached or able to be detached
```









						Lose vs. Loose vs. Loosen: What’s the Difference? - Writing Explained
					

Learn the definition of loose, loosen, and lose with example sentences and quizzes at Writing Explained.



					writingexplained.org


----------



## drhowarddrfine (Sep 10, 2020)

T-Daemon Not to go on about that but yours is the only mature response I've ever gotten to my correction. Almost always I get nasty remarks about how rude I was to point it out. One lady, on a neighborhood posting site, lambasted me in several postings over several days, with grammatical errors she later said were intentional to give me the opportunity to go off on her. One forum I visited, I got a flood of down votes (as if I cared) along with comments making me think most believe there is nothing wrong with misspelling words and grammar issues. Reddit is where you will find this issue all over the place as if they invented it.

I could go on and on but I won't. When we lose any interest in proper communication, we'll be in for a world of hurt.


----------



## judd (Sep 10, 2020)

mjollnir said:


> Alternatively, consider to invest a few bucks & buy a larger SSD. You can grep the SSD's lifetime from  smartctl -t short, wait 2 minutes, then  smartctl -l selftest.



Thanks for making me see the health of the records.
The SSD is in perfect condition, as you can see:



```
# smartctl -l selftest /dev/sdb
smartctl 7.1 2019-12-30 r5022 [x86_64-linux-5.8.7.a-1-hardened] (local build)
Copyright (C) 2002-19, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF READ SMART DATA SECTION ===
SMART Self-test log structure revision number 1
Num  Test_Description    Status                  Remaining  LifeTime(hours)  LBA_of_first_error
# 1  Short offline       Completed without error       00%      3161         -
# 2  Short offline       Completed without error       00%         0         -
# 3  Short offline       Completed without error       00%         0         -
# 4  Short offline       Completed without error       00%         0         -
```


```
# smartctl -l selftest /dev/sdb1                                                                                                                      
smartctl 7.1 2019-12-30 r5022 [x86_64-linux-5.8.7.a-1-hardened] (local build)                                                                                        
Copyright (C) 2002-19, Bruce Allen, Christian Franke, www.smartmontools.org                                                                                          

=== START OF READ SMART DATA SECTION ===                                                                                                                              
SMART Self-test log structure revision number 1                                                                                                                      
Num  Test_Description    Status                  Remaining  LifeTime(hours)  LBA_of_first_error                                                                      
# 1  Short offline       Completed without error       00%      3161         -                                                                                        
# 2  Short offline       Completed without error       00%      3161         -                                                                                        
# 3  Short offline       Completed without error       00%         0         -                                                                                        
# 4  Short offline       Completed without error       00%         0         -                                                                                        
# 5  Short offline       Completed without error       00%         0         -
```


```
# smartctl -l selftest /dev/sdb2                                                                                                                      
smartctl 7.1 2019-12-30 r5022 [x86_64-linux-5.8.7.a-1-hardened] (local build)                                                                                        
Copyright (C) 2002-19, Bruce Allen, Christian Franke, www.smartmontools.org                                                                                          

=== START OF READ SMART DATA SECTION ===                                                                                                                              
SMART Self-test log structure revision number 1                                                                                                                      
Num  Test_Description    Status                  Remaining  LifeTime(hours)  LBA_of_first_error                                                                      
# 1  Short offline       Completed without error       00%      3161         -                                                                                        
# 2  Short offline       Completed without error       00%      3161         -                                                                                        
# 3  Short offline       Completed without error       00%      3161         -                                                                                        
# 4  Short offline       Completed without error       00%         0         -                                                                                        
# 5  Short offline       Completed without error       00%         0         -                                                                                        
# 6  Short offline       Completed without error       00%         0         -
```

The HDD looks good too:


```
# smartctl -l selftest /dev/sda1                                                                                                                       
smartctl 7.1 2019-12-30 r5022 [x86_64-linux-5.8.7.a-1-hardened] (local build)                                                                                         
Copyright (C) 2002-19, Bruce Allen, Christian Franke, www.smartmontools.org                                                                                           
                                                                                                                                                                      
=== START OF READ SMART DATA SECTION ===                                                                                                                              
SMART Self-test log structure revision number 1                                                                                                                       
Num  Test_Description    Status                  Remaining  LifeTime(hours)  LBA_of_first_error                                                                       
# 1  Short offline       Completed without error       00%      4573         -                                                                                        
# 2  Short offline       Completed without error       00%      4573         -                                                                                        
# 3  Short offline       Completed without error       00%      4572         -                                                                                        
# 4  Short offline       Completed without error       00%      3976         -                                                                                        
# 5  Short offline       Completed without error       00%      3411         -                                                                                        
# 6  Short offline       Interrupted (host reset)      90%      2843         -                                                                                        
# 7  Short offline       Interrupted (host reset)      80%      1810         -                                                                                        
# 8  Short offline       Completed without error       00%       403         -                                                                                        
# 9  Extended offline    Completed without error       00%       167         -                                                                                        
#10  Short offline       Completed without error       00%       165         -                                                                                        
#11  Short offline       Completed without error       00%       104         -                                                                                        
#12  Short offline       Completed without error       00%       104         -                                                                                        
#13  Short offline       Completed without error       00%       104         -                                                                                        
#14  Short offline       Completed without error       00%       104         -                                                                                        
#15  Short offline       Completed without error       00%       104         -                                                                                        
#16  Short offline       Completed without error       00%       104         -                                                                                        
#17  Short offline       Interrupted (host reset)      80%        85         -                                                                                        
#18  Short offline       Completed without error       00%        34         -                                                                                        
#19  Short offline       Completed without error       00%        15         -                                                                                        
#20  Short offline       Completed without error       00%         1         -                                                                                        
#21  Short offline       Completed without error       00%         1         -
```


----------



## judd (Sep 10, 2020)

chrbr said:


> I would keep the SSD for Linux as it is and add a FreeBSD partition on the HDD plus one small FreeBSD swap partition. Then you can select the boot system from the boot menu of the bios or use the Linux boot manager to select Linux or FreeBSD.



I feel the same way.



chrbr said:


> I am not sure what RAID mode means here and if it can interfer with ZFS



I'm not sure about that either.



chrbr said:


> I am not sure if the chip is supported. Please see https://www.freebsd.org/releases/12.1R/hardware.html#wlan. BCM43XX are listed but BCM43XXX not. Dell Wireless 1470 is supported but Dell Wireless 1704 is not listed. You can try with booting for the installer and check the Broadcom driver. As far as I know 802.11n is not yet supported. But for normal use the internet servers are the bottle neck and not the home LAN.



Thank you for looking for the driver, even though it does not exist in FBSD, which is another stumbling block in this project. Not having WiFi is by no means less important. So I see very serious obstacles.


----------



## judd (Sep 10, 2020)

T-Daemon said:


> I would recommend the same as *@chrbr *has, I wouldn't touch the small disk, I would backup /home from the big disk, install FreeBSD root-on-ZFS on it ( with a modified installer, which lets you choose the size of the zroot partition ), recreate Pacbang Linux /home partition.



Yes, I think that would be the most logical thing to do in this case.



T-Daemon said:


> Installing both OS's on the small disc side by side would complicates the situation It would mean manual intervention because the ZFS installer doesn't let you choose on which part of the disk to install, not only that, it would wipe Linux.



It will surely erase Linux.



T-Daemon said:


> A warning, there is always a risk losing data in such a attempt, before beginning the project make a few backups of the data you don't want to lose, at least two. You should also make a backup of the Linux root partition, in case something goes wrong you can restore easily. gparted can create an .img of the whole partition in a GUI environment, unless you prefer dd(1).



Very good advice when warning me about backups.


----------



## judd (Sep 10, 2020)

mjollnir said:


> Have a look at the Dual Boot Howto & the Labeling partitions done right on modern computers.
> Don't name all your zpools _zroot, zpool, pool_ or such, but give distinctive names so you know which is what & on which disk it lives...
> I would backup that /home disk and reformat from XFS to ZFS, since that's superior & both OS can access that. Unless you want to use the brand new OpenZFS (from ports), let FreeBSD create the zpool(8) & do not allow Linux to upgrade the _zpool_'s version.
> I guess you have to manually insert a  zpool export into each OS's shutdown script: create a /etc/shutdown.local script, it will be sourced _automagically_ by /etc/rc.d/local @shutdown, i.e. you can ommit the _shebang_ comment.
> ...



Your answer makes me think that not only will I have to spend a few dollars on a larger SSD for this Ultrabox, but I am seriously considering buying a new laptop.


----------



## judd (Sep 10, 2020)

chrbr
T-Daemon
mjollnir

I am really grateful for the answers.
I also think that I am going to get into "shirt of eleven sticks" by wanting to carry out this project.
Therefore, I think, I'll leave this laptop as it is, or else, remove Linux and install only FreeBSD 12.1 (with the no lesser problem of the wifi network card ...).
I could also look for some laptops to buy.

Thanks again to all of you.


----------



## T-Daemon (Sep 10, 2020)

judd said:


> Not having WiFi is by no means less important. So I see very serious obstacles.





judd said:


> Therefore, I think, I'll leave this laptop as it is, or else, remove Linux and install only FreeBSD 12.1 (with the no lesser problem of the wifi network card



If there is a Linux driver, and there is one for BCM43142 in case of your current laptop, then it's not much of an obstacle or problem. It's possible to run in a jail OpenWRT or a linux distribution, preferable a small one, to provide the driver for the wifi adapter. 



			WiFi with AC on FreeBSD
		










						Solved - use a virtual network interface on a host?
					

Is there a way to use a virtual network interface on a physical FreeBSD host? TL;DR - yes - use epair interfaces.  Background: I have this new and quite cheap laptop (Lenovo ideapad 530S-14ARR). It was on outlet sale, therefore cheap. It doesn't have a wired ethernet interface, and the wireless...




					forums.freebsd.org


----------



## judd (Sep 10, 2020)

T-Daemon said:


> If there is a Linux driver, and there is one for BCM43142 in case of your current laptop, then it's not much of an obstacle or problem. It's possible to run in a jail OpenWRT or a linux distribution, preferable a small one, to provide the driver for the wifi adapter.
> 
> WiFi with AC on FreeBSD
> 
> ...



Wow ! very good data !


----------



## Mjölnir (Sep 11, 2020)

judd said:


> Your answer makes me think that not only will I have to spend a few dollars on a larger SSD for this Ultrabox, but I am seriously considering buying a new laptop.


In general I think we do mother earth a favour by using hardware as long as possible, since electronic stuff is very poisoning to recycle.  The guys in western Africa doing it, and those digging for rare earth elements are already having a hard time; the more we consume, the harder they live...  The BIOS is of 2012, so that machine should serve well another ~8 years for average desktop usage.  But a 32 GB SSD is rather small to provide a home for two OS + GUI nowadays.  If you're thinking of letting Linux go, you don't even need a new SSD, but only a large USB thumb drive or cheap (used/refurbished) external HDD to back up your data.


----------



## judd (Sep 11, 2020)

mjollnir said:


> If you're thinking of letting Linux go, you don't even need a new SSD, but only a large USB thumb drive or cheap (used/refurbished) external HDD to back up your data.



That's exactly what I'm doing now, I have a lot of memories that I don't want to lose, it's more than 40 GB ..


----------



## judd (Sep 11, 2020)

chrbr said:


> You can try with booting for the installer and check the Broadcom drive



Attempt made, but it doesn't work at all.

WiFi Solved with →  Adapter Nisuta 150 Mbps Wireless - Nano usb 802.11n - Model No. NS-WIU153N

Real chip <Realtek 802.11n WLAN NIC> at usbus0, cfg=0 md=HOST spd=HIGH (480 Mbps) pwr=ON (500mA)


----------



## judd (Sep 12, 2020)

Well, I have the system installed in my laptop.

* The drm-kmod package is installed.
* I have not loaded the Intel module and I am probably missing the intel screen file.
* Obviously it does not raise the X → xorg installed.
* dbus and hald more  kld_list="/boot/modules/i915kms.ko" → /etc/rc.conf
* I installed xf86-video-intel

/usr/local/etc/xorg.conf.d/intel.conf

```
Section "Device"
       Identifier        "Card0"
       Driver            "intel"
EndSection
```

/etc/loader.conf:

```
i915_load="YES"
```

I also see that the system was installed on the 32 GB SSD and on the 500 GB HDD I still have Linux, my bad, although in the installation when it asks me to "configure ZFS" and asks me on which disk I want to install it, I do it on the 32 ... ?











Thank you as always!


----------



## judd (Sep 12, 2020)

I missed something and I don't know what it is ...





I can't find a way to lift the desk...


----------



## T-Daemon (Sep 12, 2020)

judd said:


> /usr/local/etc/xorg.conf.d/intel.conf
> 
> ```
> Section "Device"
> ...



Please remove those, try it first without xorg configuration and x11-drivers/xf86-video-intel, `i915_load="YES"` would load the kernel module coming with the GENERIC kernel, not the module coming with graphics/drm-kmod ( graphics/drm-fbsd12.0-kmod ).

Follow the recommended Intel Integrated Graphics tutorial:


Spoiler



Example Configuration For Post Broadwell System

A common configuration is a user who has an Intel laptop with a Kabylake Intel i915 HD Graphics chip. To enable the chipset one would follow these instructions:

    Install the drm-kmod package

        $ sudo pkg install drm-kmod
    Take note of the post-install package message as it contains important information - specifically add this to your /etc/rc.conf or /etc/rc.conf.d/intel file:

        kld_list="/boot/modules/i915kms.ko"
    Ensure your UID is a member of the "video" group.
    Restart your system; you should see the i915kms.ko get loaded and a flash on your console as we switch over to the new display driver.
    Start Xorg via your usual method (i.e. startx, GDM, etc.)

Note: For systems that are able to take advantage of this updated DRM code you do not need to prepare an xorg.conf configuration file, and installing the xf86-video-intel port is optional. Our Xorg should autodetect the driver, and utilize the modesetting Xorg driver and glamor driver.


In the future, when installing ports/packages, many come with a post-install message, get used to notice those. You can read those messages also afterwards: `pkg info -D drm-fbsd12.0-kmod`.


A note, if the xorg server doesn't start and you want to post  /var/log/Xorg.0.log, or any other text files, or standard output like from `pciconf -vl`, don't take pictures, use nc(1) (netcat):

Examples:
`cat /var/log/Xorg.0.log | nc termbin.com 9999`
`pciconf -vl | grep -B3 display | nc termbin.com 9999`

Those commands will return a URL of the uploaded text from https://termbin.com, post that URL, or open yourself from the browser your are logging into forums FreeBSD the URL and copy/paste it in your posting. That will relieve you going through the hassle of taking pictures and it will decrease the thread page download size. Each picture has ~2 MB or even more, not to mention the disc space saved on the forums servers, not from your pictures alone but in summary from other postings together.


----------



## judd (Sep 12, 2020)

T-Daemon said:


> Those commands will return a URL from the uploaded text on https://termbin.com, post that URL , or open yourself from the browser your are logging into forums FreeBSD the URL and copy/paste it in your posting. That will relieve you going through the hassle of taking pictures and it will decrease the thread page download size.



Thank you, noted.

cat /var/log/Xorg.0.log | nc termbin.com 9999 → https://termbin.com/bvvk

pciconf -vl | grep -B3 display | nc termbin.com 9999 → https://termbin.com/mx9xe

pciconf -vl | grep -B 4 vga | nc termbin.com 9999 → https://termbin.com/a1edt

pciconf -vl | nc termbin.com 9999 →  https://termbin.com/y1sz



T-Daemon said:


> Each picture has ~2 MB or even more, not to mention the disc space saved on the forums servers, not from your pictures alone but in summary from other postings together.



I understand, I apologize.
Edit: I changed the images to 640x480


----------



## Mjölnir (Sep 12, 2020)

Delete that line `i915_load="YES"` from loader.conf(5).
`kldstat -v | grep i915` should show `/boot/modules/i915kms.ko`
1st try to let Xorg _automagic autoconfig,_ without any manual configuration files.  Move /usr/local/etc/X11/xorg.conf.d/* out of the way.
`startx` or `service sddm start` (or whatever display manager you installed)


----------



## judd (Sep 12, 2020)

mjollnir said:


> Delete that line  i915_load="YES" from loader.conf(5).



Done.



mjollnir said:


> kldstat -v | grep i915 should show  /boot/modules/i915kms.ko



https://termbin.com/46ua



mjollnir said:


> Move /usr/local/etc/X11/xorg.conf.d/* out of the way.



I can imagine erasing it, can't I ?


----------



## Mjölnir (Sep 12, 2020)

Of course, but you may keep them somewhere to re-use them in case you want to manually change some options later.  You can post short output (a few lines) inline here, but for large output like a log file use _termbin.com_ or alike (e.g. misc/pastebinit).


----------



## judd (Sep 12, 2020)

mjollnir said:


> or alike (e.g. misc/pastebinit).



Thanks, if I have it installed, but it wasn't working well... that's why I use termbin.com


----------



## judd (Sep 12, 2020)

mjollnir said:


> Of course,



 Well, now everything works







except the touchpad ?


----------



## Mjölnir (Sep 12, 2020)

put `message              "query '[%C/%n] %M'",` into the _ALIAS_ section of /usr/local/etc/pkg.conf
`pkg message xorg-server`
`sysctl kern.evdev.rcpt_mask=6` and `echo kern.evdev.rcpt_mask=6 >>/etc/sysctl.conf`
`sysrc moused_flags+=" -l 2"` to set moused(8) to operate in psm(4) extended level
`echo hw.psm.synaptics_support=\"1\" >>/boot/loader.conf`
`hw.psm.trackpoint_support=\"1\" >>/boot/loader.conf`
(or /boot/loader.conf.local). If you not already have that, reboot.
It's a good idea to read through all `pkg message | less` and do as instructed, anyway.


----------



## judd (Sep 12, 2020)

mjollnir said:


> It's a good idea to read through all  pkg message | less and do as instructed, anyway.



Thanks mjollnir 
I'll get right on it.
I haven't gone to bed yet, I've been reading and learning about this operating system. I'm not tired anymore.

I made several advances:
* kde5 installed.
* the whole system in UTF-8 in Spanish.
* Konsole in Spanish with the letter ñ
* Plasma set and ready.

* Now I need to configure the touchpad to work, now I work with mouse/usb.


----------



## judd (Sep 12, 2020)

mjollnir said:


> put  message 'query '[%C/%n] %M'', into the _ALIAS_ section of /usr/local/etc/pkg.conf




```
ALIAS              : {
  all-depends: query %dn-%dv,
  annotations: info -A,
  build-depends: info -qd,
  cinfo: info -Cx,
  comment: query -i "%c",
  csearch: search -Cx,
  desc: query -i "%e",
  download: fetch,
  iinfo: info -ix,
  isearch: search -ix,
  prime-list: "query -e '%a = 0' '%n'",
  prime-origins: "query -e '%a = 0' '%o'",
  leaf: "query -e '%#r == 0' '%n-%v'",
  list: info -ql,
  list: info -ql,
  message 'query '[%C/%n] %M'',  >>>>>>>>>>>>>>done
  noauto = "query -e '%a == 0' '%n-%v'",
  options: query -i "%n - %Ok: %Ov",
  origin: info -qo,
  provided-depends: info -qb,
  rall-depends: rquery %dn-%dv,
  raw: info -R,    
  rcomment: rquery -i "%c",
  rdesc: rquery -i "%e",
  required-depends: info -qr,
  roptions: rquery -i "%n - %Ok: %Ov",
  shared-depends: info -qB,
  show: info -f -k,
```



mjollnir said:


> pkg message xorg-server



`# pkg message xorg-server
pkg: Invalid configuration file: error while parsing <unknown>: line: 72, col
umn: 10 - 'key must begin with a letter', character: '''
pkg: unknown command: message`

According to this link, inverted commas are missing. https://forums.freebsd.org/threads/kmix-is-not-launched-from-kde5-panel.75863/post-466544 and then it would be:
message "query '[%C/%n] %M'",  ? I don't know.  Neither of the two ways make the touchpad work.


Points 3,4,and 5 without problems.


----------



## judd (Sep 13, 2020)

Now it works.
https://wiki.freebsd.org/SynapticsTouchpad:

To enable psm(4) Synaptics support, add the following line to /boot/loader.conf

`hw.psm.synaptics_support="1"`

Enable moused(8). Add the following to /etc/rc.conf

`moused_enable="YES"`

To use it within X.Org, disable the X.Org-specific Synaptics driver, and configure a sysmouse mouse. Here's an example section for /etc/X11/xorg.conf

`Section "InputDevice"
    Identifier      "Mouse0"
    Driver          "mouse"
    Option          "Protocol"      "auto"
    Option          "Device"        "/dev/sysmouse"
    Option          "ZAxisMapping"  "4 5 6 7"
EndSection`

Horizontal scrolling is disabled by default. To enable it, add the following to /etc/sysctl.conf

`hw.psm.synaptics.vscroll_hor_area=1300`


----------



## Mjölnir (Sep 13, 2020)

judd said:


> `# pkg message xorg-server
> pkg: Invalid configuration file: error while parsing <unknown>: line: 72, col
> umn: 10 - 'key must begin with a letter', character: '''
> pkg: unknown command: message`
> ...


Yes, sorry for that flaw.  I edited my previous post.  You don't need a xorg.conf(5) entry or file for the mouse, it should be autodetected.  If you do not run moused(8) on level 2, the _TouchPad_ & _TrackPoint_ will be detected as a PS/2 mouse.  If you install the x11-input-synaptics _TouchPad_ driver, you can comfortably configure it via the KDE _control-center_ (`systemsettings5`) & enjoy the advanced settings.
My `sysrc moused_flags="-a 1.5 -A 1.5,2 -VH -L 3 -U 3 -l 2"` (touchpad) and
`sysrc moused_ums0_flags="-A 1.5,2 -l 2"` (USB mouse), YMMV.


----------



## joplass (Apr 25, 2021)

drhowarddrfine said:


> T-Daemon Not to go on about that but yours is the only mature response I've ever gotten to my correction. Almost always I get nasty remarks about how rude I was to point it out. One lady, on a neighborhood posting site, lambasted me in several postings over several days, with grammatical errors she later said were intentional to give me the opportunity to go off on her. One forum I visited, I got a flood of down votes (as if I cared) along with comments making me think most believe there is nothing wrong with misspelling words and grammar issues. Reddit is where you will find this issue all over the place as if they invented it.
> 
> I could go on and on but I won't. When we lose any interest in proper communication, we'll be in for a world of hurt.



English is my 3rd language. I always want to speak it or write it correcly and so I also always thank those who take the time to correct me.


----------



## debguy (May 3, 2021)

I have Android X86, Windows 10, Linux, FreeBSD on one PC - none of them virtual.

My policy is:  windows10 gets drive#1 NTFS whatever it demands.  The rest boot from USB.  I have had zero problems that way.

My lovely asian bios let's me pick which HD to boot from.  That is how I boot into FreeBSD.  If it didn't I'd have had to have a USB boot stick for USB (installer usb i have) and find the command to boot the images on the hard drive not the images on the USB.  For linux I already have a grub usb and am hugely un-interested if it can boot freeBSD.

The thing is:  booting is part of the software wars.  Just stay away from it with a 10 foot pole and you'll run into 0 problems booting


----------



## Alain De Vos (May 3, 2021)

I have good experiences with chainloading grub. Where the grub bootloader only needs to find the freebsd bootloader.


----------

