Benutzer:PaulRiegel/TrueOS: Unterschied zwischen den Versionen

Aus Wiki StuRa HTW Dresden
Zur Navigation springen Zur Suche springen
 
(5 dazwischenliegende Versionen desselben Benutzers werden nicht angezeigt)
Zeile 708: Zeile 708:
== mirroring ==
== mirroring ==


=== Ersetzen von einem Massenspeicher als Teil von einem mirror ===
[[Benutzer Diskussion:PaulRiegel/TrueOS#mirroring]]


WIP
== SWAP ==


: <code>zpool status</code>
wir nehmen an, dass das Gerät (für Massenspeicher) ''/dev/ada0'' ist
<pre>
  pool: vzfspool
state: DEGRADED
status: One or more devices could not be opened.  Sufficient replicas exist for
        the pool to continue functioning in a degraded state.
action: Attach the missing device and online it using 'zpool online'.
  see: http://illumos.org/msg/ZFS-8000-2Q
  scan: scrub repaired 0 in 0h1m with 0 errors on Sun mm dd HH:MM:SS yyyy
config:
 
        NAME                    STATE    READ WRITE CKSUM
        vzfspool                DEGRADED    0    0    0
          mirror-0              DEGRADED    0    0    0
            4561791786978147166  UNAVAIL      0    0    0  was /dev/ada0p2.eli
            ada1p2.eli          ONLINE      0    0    0
 
errors: No known data errors
</pre>
: <code>sudo zpool online vzfspool 4561791786978147166</code>
<pre>
warning: device '4561791786978147166' onlined, but remains in faulted state
use 'zpool replace' to replace devices that are no longer present
</pre>
: <code>zpool replace vzfspool 4561791786978147166</code>
<pre>
cannot open '4561791786978147166': no such GEOM provider
must be a full path or shorthand device name
</pre>
: <code>zpool replace vzfspool /dev/ada0p2.eli</code>
<pre>
cannot open '/dev/ada0p2.eli': No such file or directory
</pre>
: <code>sudo zpool detach vzfspool /dev/ada0p2.eli</code>
<pre></pre>
: <code>zpool status</code>
<pre>
  pool: vzfspool
state: DEGRADED
status: One or more devices could not be opened.  Sufficient replicas exist for
        the pool to continue functioning in a degraded state.
action: Attach the missing device and online it using 'zpool online'.
  see: http://illumos.org/msg/ZFS-8000-2Q
  scan: scrub repaired 0 in 0h1m with 0 errors on Sun mm dd HH:MM:SS yyyy
config:


        NAME                    STATE    READ WRITE CKSUM
: wir versuchen es gleich einmal richtig (mit dem labeling) zu machen, um probleme - welches gerät erhält welche forlaufende nummer - zu vermeiden.
        vzfspool                DEGRADED    0    0    0
          mirror-0              DEGRADED    0    0    0
            4561791786978147166  UNAVAIL      0    0    0  was /dev/ada0p2.eli
            ada1p2.eli          ONLINE      0    0    0


errors: No known data errors
</pre>
: <code>sudo zpool detach vzfspool /dev/ada0p2.eli</code>
<pre></pre>
: <code>zpool status</code>
<pre>
  pool: vzfspool
state: ONLINE
  scan: scrub repaired 0 in 0h1m with 0 errors on Sun mm dd HH:MM:SS yyyy
config:
        NAME          STATE    READ WRITE CKSUM
        vzfspool      ONLINE      0    0    0
          ada1p2.eli  ONLINE      0    0    0
errors: No known data errors
: <code>gpart show</code>
: <code>gpart show</code>
<pre>
<s>
=>       34  976773101  ada0 GPT (466G)
: <code>gpart destroy /dev/ada0</code>
        34      2014        - free - (1.0M)
: <code>gpart create -s MBR /dev/ada0</code>
      2048  976771072    1  linux-data  (466G)
: <code>gpart create -s GPT /dev/ada0</code>
  976773120        15        - free - (7.5K)
: <code>gpart add -t freebsd-swap -l swap /dev/ada0</code>
: <code>gpart add -t freebsd-swap /dev/ada0</code>
</s>


=>      40  976773088  ada1  GPT  (466G)
: <code>glabel status</code>
        40        512    1  freebsd-boot  (256K)
        552  934799360    2  freebsd-zfs  (446G)
  934799912  41943040    3  freebsd-swap  (20G)
  976742952      30176        - free -  (15M)
: <code>gpart backup ada1</code>
<pre>
<pre>
GPT 152
</pre>
1  freebsd-boot        40      512 
2    freebsd-zfs      552 934799360 
3  freebsd-swap 934799912  41943040 
: <code>gpart backup ada1 | gpart restore -F ada0</code>
<pre>
gpart backup ada1 | gpart restore -F ada0
: <code>gpart show</code>
<pre>
=>      40  976773088  ada0  GPT  (466G)
        40        512    1  freebsd-boot  (256K)
        552  934799360    2  freebsd-zfs  (446G)
  934799912  41943040    3  freebsd-swap  (20G)
  976742952      30176        - free -  (15M)


=>       40  976773088  ada1  GPT  (466G)
<s>
        40        512    1  freebsd-boot  (256K)
: <code>newfs -L swap /dev/ada0</code>
        552  934799360    2  freebsd-zfs  (446G)
</s>
  934799912  41943040    3  freebsd-swap (20G)
<s>
  976742952      30176        - free -  (15M)
: <code>tunefs -L swap /dev/ada0</code>
</pre>
</s>
: <code>zpool status</code>
: <code>glabel label swap /dev/ada0</code>
<pre>
  pool: vzfspool
state: ONLINE
  scan: scrub repaired 0 in 0h1m with 0 errors on Sun mm dd HH:MM:SS yyyy
config:


        NAME          STATE    READ WRITE CKSUM
: <code>swapon /dev/label/swap</code>
        vzfspool      ONLINE      0    0    0
          ada1p2.eli  ONLINE      0    0    0


errors: No known data errors
: <code>$EDITOR /etc/fstab</code>
</pre>
: <code>ls /dev/ | grep ada</code>
<pre>
<pre>
procfs                  /proc                  procfs          rw      0      0
linprocfs              /compat/linux/proc      linprocfs      rw      0      0
/dev/label/efibsd      /boot/efi              msdosfs        rw      0      0
</pre>
</pre>
: <code>zpool attach vzfspool /dev/ada1 /dev/ada0</code>
<pre>
<pre>
cannot attach /dev/ada0 to /dev/ada1: no such device in pool
/dev/label/swap        none                    swap            sw      0      0
</pre>
</pre>
: <code>geli backup /dev/ada1p2 ~/geli.backup</code>
 
<pre></pre>
: <code>glabel status</code>
: <code>sudo geli restore ~/geli.backup /dev/ada0p2</code>
<pre></pre>
: <code>ls /dev | grep ada</code>
<pre>
ada0
ada0p1
ada0p2
ada0p3
ada1
ada1p1
ada1p2
ada1p2.eli
ada1p3
</pre>
: <code>geli attach /dev/ada0p2</code>
<pre>
<pre>
Enter passphrase:
</pre>
: <code>geli status</code>
<pre>   
          Name  Status  Components
    ada1p2.eli  ACTIVE  ada1p2
label/swap0.eli  ACTIVE  label/swap0
    ada0p2.eli  ACTIVE  ada0p2
</pre>
</pre>
: <code>ls /dev | grep ada</code>                                           
<pre>
ada0
ada0p1
ada0p2
ada0p2.eli
ada0p3
ada1
ada1p1
ada1p2
ada1p2.eli
ada1p3
</pre>
: <code>sudo zpool attach vzfspool /dev/ada0p2.eli /dev/ada1p2.eli</code>
<pre>
Make sure to wait until resilver is done before rebooting.


If you boot from pool 'vzfspool', you may need to update
: <code>glabel list</code>
boot code on newly attached disk '/dev/ada1p2.eli'.
 
Assuming you use GPT partitioning and 'da0' is your new boot disk
you may use the following command:
 
        gpart bootcode -b /boot/pmbr -p /boot/gptzfsboot -i 1 da0
 
</pre>
: <code>gpart bootcode -b /boot/pmbr -p /boot/gptzfsboot -i 1 ada1p1</code>
<pre>
gpart: No such geom: ada0p1.
</pre>
: <code>sudo gpart bootcode -b /boot/pmbr -p /boot/gptzfsboot -i 1 /dev/ada1</code>
<pre>
partcode written to ada1p1
bootcode written to ada1
</pre>
: <code>geli status</code>
<pre>
<pre>
          Name  Status  Components
    ada0p2.eli  ACTIVE  ada0p2
    ada1p2.eli  ACTIVE  ada1p2
label/swap0.eli  ACTIVE  label/swap0
</pre>
</pre>
: <code>sudo zpool attach vzfspool /dev/ada1p2.eli /dev/ada0p2.eli</code>
<pre>
invalid vdev specification
use '-f' to override the following errors:
/dev/ada0p2.eli is part of active pool 'vzfspool'
</pre>
: <code>sudo zpool attach vzfspool /dev/ada0p2.eli /dev/ada1p2.eli</code>
<pre>
invalid vdev specification
use '-f' to override the following errors:
/dev/ada0p2.eli is part of active pool 'vzfspool'
</pre>
: <code>zpool status                                             
</code>
<pre>
  pool: vzfspool
state: ONLINE
  scan: resilvered 12.3G in 0h1m with 0 errors on Sun mm dd HH:MM:SS yyyy
config:


        NAME            STATE    READ WRITE CKSUM
<s>
        vzfspool        ONLINE      0    0    0
: <code>glabel destroy swap</code>
          mirror-0      ONLINE      0    0    0
</s>
            ada1p2.eli  ONLINE      0    0    0
            ada0p2.eli  ONLINE      0    0    0
 
errors: No known data errors
</pre>

Aktuelle Version vom 25. November 2017, 18:22 Uhr

Diese Seite ist lediglich ein Merkzettel für mich.

Installation[Bearbeiten]

Dinge, die sich nach der Installation einmal angeschaut werden kann[Bearbeiten]

Arbeitsspeicher[Bearbeiten]

mit SWAP
swapinfo
Device          512-blocks     Used    Avail Capacity
/dev/label/swap0.eli   41943032        0 41943032     0%
sudo swapon -a

sudo swapoff -a
swapoff: removing /dev/label/swap0.eli as swap device
swapinfo
Device          512-blocks     Used    Avail Capacity
sudo swapon -a
swapon: adding /dev/label/swap0.eli as swap device
sudo swapon -F /etc/fstab -a

Massenspeicher[Bearbeiten]

mit GEOM_ELI
mit ZFS
Verschlüsslung
geom_eli_load="YES"
geli status
geli list
Pool
zfs_enable="YES"
als Spiegel von zwei Massenspeichern
zpool status
zfs list
zfs list -t snapshot

FreeBSD-CURRENT 12[Bearbeiten]

foo for TrueOS[Bearbeiten]

freshporting TrueOS[Bearbeiten]

WTF! TrueOS wurde von stable auf current umgestellt und gibt nur noch eingefrorene (gelegentlich dann) wochenalte Pakete?
http://pkg.cdn.trueos.org/master/amd64/ (i.V.m. http://pkg.cdn.trueos.org/master/amd64-base/ ) vs. http://pkg.freebsd.org/freebsd:12:x86:64/latest/
cat /usr/local/etc/pkg/repos/trueos.conf
trueos-major: {
                url: "http://pkg.cdn.trueos.org/master/amd64",
                signature_type: "fingerprints",
                fingerprints: "/usr/local/etc/pkg/fingerprints/trueos",
                enabled: true
              }
sudo ee /usr/local/etc/pkg/repos/trueos.conf
Der Einfachheit halber wird das Repository einfach frei wählbar als freebsd bezeichnet. (Genau genommen könnte es der Klarheit halber auch pkg-freebsd-12-x86-64 benannt werden.)
aus https://svnweb.freebsd.org/base/head/etc/pkg/FreeBSD.conf?view=co ( alternativ per https://github.com/freebsd/freebsd/blob/master/etc/pkg/FreeBSD.conf ) übernommen

freebsd: {             
           url: "pkg+http://pkg.freebsd.org/freebsd:12:x86:64/latest",
           mirror_type: "srv",       
           signature_type: "fingerprints",
           fingerprints: "/usr/share/keys/pkg",
           enabled: true
         }
sudo ln -s /usr/share/keys/pkg /usr/local/etc/pkg/fingerprints/freebsd
im Stil von dem Beispiel von https://www.freebsd.org/cgi/man.cgi?query=pkg-repo&sektion=8 (statt # Add 'fingerprint' into /usr/local/etc/pkg/fingerprints/myrepo/trusted)

einzelne Software[Bearbeiten]

CBSD[Bearbeiten]

sudo pkg install -y cbsd
Message from cbsd-11.0.2:
===============================================================================

cbsd is now installed, but requires additional setup steps:

Upon initial installation, run:

  env workdir="/path" /usr/local/cbsd/sudoexec/initenv

Where /path is the path to the cbsd workdir, e.g.: /usr/jails

For upgrading an existing installation, run:

  cbsd initenv

===============================================================================
sudo env workdir="/usr/jails" /usr/local/cbsd/sudoexec/initenv
-------[CBSD v.11.0.2]-------
 This is install/upgrade scripts for CBSD.
 Don't forget to backup.
-----------------------------
Do you want prepare or upgrade hier environment for CBSD now?
[yes(1) or no(0)]
1

[Stage 2: build tools]                                                                                                                                        
exec: /usr/local/bin/clang38: not found
exec: /usr/local/bin/clang38: not found
Shall i add cbsd user into /usr/local/etc/sudoers.d/cbsd_sudoers sudo file to obtain root privileges for the most cbsd commands?
[yes(1) or no(0)]
^C
sudo pkg install -y clang38
sudo env workdir="/usr/jails" /usr/local/cbsd/sudoexec/initenv

/usr/bin/ld: warning: libssl.so.8, needed by /usr/local/lib/libssh2.so, not found (try using -rpath or -rpath-link)

sudo ln -s /usr/local/lib/libssl.so.39 /usr/local/lib/libssl.so.8
sudo env workdir="/usr/jails" /usr/local/cbsd/sudoexec/initenv

[Stage 2: build tools]                                                                                                                                        
/usr/bin/ld: warning: libcrypto.so.8, needed by /usr/local/lib/libssh2.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: libcrypto.so.8, needed by /usr/local/lib/libssh2.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: libcrypto.so.8, needed by /usr/local/lib/libssh2.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: libcrypto.so.8, needed by /usr/local/lib/libssh2.so, not found (try using -rpath or -rpath-link)
Shall i add cbsd user into /usr/local/etc/sudoers.d/cbsd_sudoers sudo file to obtain root privileges for the most cbsd commands?
[yes(1) or no(0)]
^C
sudo ln -s /usr/local/lib/libcrypto.so.38 /usr/local/lib/libcrypto.so.8


sudo env workdir="/usr/jails" /usr/local/cbsd/sudoexec/initenv
-------[CBSD v.11.0.2]-------
 This is install/upgrade scripts for CBSD.
 Don't forget to backup.
-----------------------------
Do you want prepare or upgrade hier environment for CBSD now?
[yes(1) or no(0)]
1
>>> Installing or upgrading
[Stage 1: account & dir hier]
 * Check hier and permission...
[Stage 2: build tools]                                                                                                                                        
Shall i add cbsd user into /usr/local/etc/sudoers.d/cbsd_sudoers sudo file to obtain root privileges for the most cbsd commands?
[yes(1) or no(0)]
1
[Stage 3: local settings]
Shall i modify the /etc/rc.conf to sets cbsd_workdir="/usr/jails"?: 
[yes(1) or no(0)]
1
/etc/rc.conf: cbsd_workdir:  -> /usr/jails
[Stage 4: update default skel resolv.conf]
[Stage 5: freshing inventory]
nodename: Short form nodename for this host e.g. like hostname. Warning: this operation will recreate the ssh keys in /usr/jails/.ssh dir: dev.domain.tld                                                                                                                                                          

Empty inventory database created: /usr/jails/var/db/inv.dev.domain.tld.sqlite
nodeip: Node management IPv4 or IPv6 address (used for node interconnection), e.g: 192.168.178.125

jnameserver: Jails default DNS name-server (for jails resolv.conf), e.g.: 8.8.8.8,8.8.4.4

nodeippool: Jail pool IP address range (networks for jails)
Hint: use space as delimiter for multiple networks, e.g.: 10.0.0.0/16 192.168.178.125/24

nat_enable: Enable NAT for RFC1918 networks?
[yes(1) or no(0)]
1
Set IP address or NIC as the aliasing NAT address or interface, e.g: 192.168.178.125

Which NAT framework do you want to use: [pf]
(type FW name, eg pf,ipfw,ipfilter or "exit" for break)

Do you want to modify /boot/loader.conf to set pf_load=YES ?
[yes(1) or no(0)]
1
/boot/loader.conf: pf_load:  -> YES
fbsdrepo: Use official FreeBSD repository? When no (0) repository of CBSD is preferred (usefull for stable=1) for fetching base/kernel?
[yes(1) or no(0)]
1
zfsfeat: You are running on a ZFS-based system. Enable ZFS feature?
[yes(1) or no(0)]
1
parallel: Parallel mode stop/start ?
(0 - no parallel or positive value (in seconds) as timeout for next parallel sequence) e.g: 5

stable: Use STABLE branch (RELENG_10 (ver = 10) instead of RELEASE_10.x (ver = 10.x) ). Only CBSD repository have binary base for STABLE branch ?
(STABLE_X instead of RELEASE_X_Y branch for base/kernel will be used), e.g.: 0 (use release)
11
sqlreplica: Enable sqlite3 replication to remote nodes ?
(0 - no replica, 1 - try to replicate all local events to remote nodes) e.g: 1

[Stage 6: authentication keys]
Generating public/private rsa key pair.
Your identification has been saved in /usr/jails/.ssh/3f4593ce1717ce911a89014463d6475e.id_rsa.
Your public key has been saved in /usr/jails/.ssh/3f4593ce1717ce911a89014463d6475e.id_rsa.pub.
The key fingerprint is:
SHA256:X/uebO19P2cA8xS1zRcp5br8Q+C8e2wm0M82C0e/eO0 root@dev.domain.tdl
The key's randomart image is:
+---[RSA 2048]----+
|              .+o|
|             .oo+|
|              .++|
|            o.o .|
|        S   =*.. |
|         . o.==..|
|          . o+*+o|
|             =*#O|
|             =&BE|
+----[SHA256]-----+
[Stage 7: modules]
Installing module pkg.d cmd: pkg
Installing module bsdconf.d cmd: tzsetup
Installing module bsdconf.d cmd: ssh
Installing module bsdconf.d cmd: ftp
Installing module bsdconf.d cmd: adduser
Installing module bsdconf.d cmd: passwd
Installing module bsdconf.d cmd: service
Installing module bsdconf.d cmd: sysrc
Installing module bsdconf.d cmd: userlist
Installing module bsdconf.d cmd: grouplist
Installing module bsdconf.d cmd: adduser-tui
Installing module bsdconf.d cmd: pw
Installing module zfsinstall.d cmd: zfsinstall
[Stage 9: cleanup]
 * Remove obsolete files...
Configure RSYNC services for jail migration?                                                                                                                  
[yes(1) or no(0)]
1
Shall i modify the /etc/rc.conf to sets cbsdrsyncd_enable="YES"
[yes(1) or no(0)]
1
/etc/rc.conf: cbsdrsyncd_enable:  -> YES
Do you want to modify /etc/rc.conf to set the cbsdrsyncd_flags="--config=/usr/jails/etc/rsyncd.conf" ?
[yes(1) or no(0)]
1
/etc/rc.conf: cbsdrsyncd_flags:  -> --config=/usr/jails/etc/rsyncd.conf
/usr/local/etc/rc.d/cbsdrsyncd: required_files:  -> 
Starting cbsdrsyncd.
Shall i modify the /etc/rc.conf to sets cbsdd_enable=YES ?
[yes(1) or no(0)]
1
/etc/rc.conf: cbsdd_enable:  -> YES
Shall i modify the /etc/rc.conf to sets rcshutdown_timeout="900"?
[yes(1) or no(0)]
1
/etc/rc.conf: rcshutdown_timeout: 90 -> 900
Shall i modify default SSH daemon port from 22 to 22222 on this host via /etc/rc.conf and sshd_flags="-oPort=22222" which is default for cbsd?
[yes(1) or no(0)]
1
/etc/rc.conf: sshd_flags:  -> -oPort=22222
[Stage X: upgrading]
>>> Done
  First CBSD initialization complete.
                                                                                                                                                              
  Now your can run:                                                                                                                                           
  service cbsdd start                                                                                                                                         
  to run CBSD services.                                                                                                                                       
                                                                                                                                                              
  For change initenv settings in next time, use:                                                                                                              
  cbsd initenv-tui                                                                                                                                            
                                                                                                                                                              
  Also don't forget to execute:                                                                                                                               
  cbsd initenv                                                                                                                                                
  every time when you upgrade CBSD version.                                                                                                                   
sudo service cbsdd start
Starting cbsdd.

PC-BSD 10.1[Bearbeiten]

System bei PC-BSD 10.1 betreuen[Bearbeiten]

Software bei PC-BSD 10.1 aktuell halten[Bearbeiten]

Siehe auch
Wiki PC-BSD:Update_Manager/10.1

unterhalb der GUI FreeBSD aktuell halten

freebsd-update fetch && freebsd-update install

unterhalb der GUI PC-BSD aktuell halten

pc-updatemanager check && pc-updatemanager install

unterhalb der GUI Pakete (pkg) aktuell halten

pc-updatemanager pkgcheck && pc-updatemanager pkgupdate

manuelles Konfigurieren von Netzwerkschnittstellen[Bearbeiten]

manuelles Konfigurieren von Netzwerkschnittstellen beim Laptop[Bearbeiten]

Grundlage ist folgendes Szenario:

  • Es gibt eine Netzwerkschnittstelle für LAN em0.
  • Es gibt eine Netzwerkschnittstelle für WLAN iwn0.
  • Es soll eine Bevorzugung vom LAN gegenüber WLAN geben. Im Falle des Ausfalls (mangelnder Verfügbarkeit) der Verbindung für LAN soll automatisch die Verbindung für WLAN genutzt werden.
Allgemeines

In der Kombination von laggproto (für failover) und allgemeiner Nutzung von IPv6 (ipv6_activate_all_interfaces="YES") kommt es zum Crash vom Kernel bei (FreeBSD 10.1 und demnach auch bei) PC-BSD 10.1.

PC-BSD erstellt für die Datei rc.conf folgende Einträge.
ifconfig_em0="UP"
wlans_iwn0="wlan0"
ifconfig_wlan0="WPA"
ifconfig_iwn0="`ifconfig em0 ether`"
ifconfig_iwn0="ether ${ifconfig_iwn0##*ether }"
cloned_interfaces="lagg0"
ifconfig_lagg0="laggproto failover laggport em0 laggport wlan0 SYNCDHCP"
Für mich habe ich für die Datei rc.conf folgende Einträge erstellt.

Achtung! Dieser Abschnitt ist nur einmal auf die Schnelle entstanden und nur bedingt (funktionell) geprüft.

grundsätzlich Gedanken dazu potentielle Definition als Lösungsansatz
LAN muss verfügbar sein.
Die Schnittstelle em0 für LAN muss da sein.
ifconfig_em0="UP"
WLAN muss verfügbar sein.
Die Schnittstelle iwn0 muss da sein.
ifconfig_iwn0="UP"
Die Schnittstelle iwn0 soll (als frei wählbare Bezeichnung) wlan0 als Schnittstelle für WLAN verwendet werden.
wlans_iwn0="wlan0"
Die Schnittstelle für WLAN wlan0 soll wpa_supplicant verwenden.
ifconfig_wlan0="WPA"
Es müssen LAN und WLAN verknüpft, und die Verknüpfung geregelt sein.
Eine künstliche Schnittstelle (als frei wählbare Bezeichnung) lagg0 muss erstellt und konfiguriert sein.
cloned_interfaces="lagg0"
Die MAC-Adressen (ifconfig interface ether | grep ether) dürfen sich nicht unterscheiden. Um ihnen den gleichen Wert zuzuweisen, muss die MAC-Adresse der maßgeblichen Schnittstelle allen anderen zugeordneten Schnittstellen zugewiesen werden.
ifconfig_iwn0="ether `ifconfig em0 ether | grep ether | awk '{print $2}'`"
Es muss für die künstliche Schnittstelle definiert werden, welche der bestehenden Schnittstellen die Bevorzugte und welche die Nachgelagerte (zum Ausweichen) ist.
Die künstliche Schnittstelle soll (als synchronous_dhclient) DHCP lease beziehen.
ifconfig_lagg0="laggproto failover laggport em0 laggport wlan0 SYNCDHCP"
ee /etc/rc.conf
###     ###     ###     network

###     ###     ####    IPv6
#ipv6_activate_all_interfaces="YES"
ip6addrctl_policy="ipv6_prefer"

###     ###     ####    LAN
ifconfig_em0="UP"
ifconfig_em0_ipv6="inet6 accept_rtadv"

###     ###     ####    WLAN
ifconfig_iwn0="UP"
wlans_iwn0="wlan0"
ifconfig_wlan0_ipv6="inet6 accept_rtadv"
ifconfig_wlan0="WPA"

###     ###     ####    failover
cloned_interfaces="lagg0"
ifconfig_iwn0="ether `ifconfig em0 ether | grep ether | awk '{print $2}'`"
ifconfig_lagg0="laggproto failover laggport em0 laggport wlan0 SYNCDHCP"
#ifconfig_lagg0_ipv6="inet6 accept_rtadv"

KDE[Bearbeiten]

Oxygen[Bearbeiten]

Anwendungen für GTK auch schön als Oxygen darstellen
pkg install gtk-oxygen-engine
Im Übrigen ist vielleicht ergänzend auch noch gtk3-oxygen-engine nötig.

eigenes Theme erstellen[Bearbeiten]

forking the current theme

Eigentlich wollte ich nur das Bild vom Hintergrund für den gesperrten Bildschirm ändern. Daraus wurde dann (auf die Schnelle) das Erstellen eines eigenen Theme.

Um nur das Hintergrundbild (je Account) für den gesperrten Bildschirm zu ändern fand sich via Suchmaschine schnell eine Anleitung. Das inspirierte aber zu mehr.

Anstatt png kann auch jpg verwendet werden.

Ordner für eigene Bilder für den Hintergrund für das eigene Theme erstellen und (standardmäßig) strukturieren
einfach die Struktur vom aktuellen Stand übernehmen
cp -r /usr/local/share/wallpapers/Elarun /usr/local/share/wallpapers/PaulRiegel
Dem entsprechend sind "alte" Bilder der kopierten Vorlage folglich zu löschen (bzw.) zu ersetzen.
oder
alternativ und eigentlich besser die Struktur entsprechend erstellen (und befüllen)
Hauptverzeichnis für die Bilder des Hintergrundes erstellen
mkdir /usr/local/share/wallpapers/PaulRiegel
Unterverzeichnisse für die Bilder des Hintergrundes erstellen
mkdir -p /usr/local/share/wallpapers/PaulRiegel/contents/images
Eigentlich gehört (scheinbar) in /usr/local/share/wallpapers/PaulRiegel/contents ein Bild zur Vorschau (400 px x 250 px) mit dem Namen der Datei screenshot.png.
Kopieren der Bilder für den Hintergrund
cp ~/Images/Hintergrundbild /usr/local/share/wallpapers/PaulRiegel/contents/images/1280x800.png
Die Bezeichnung der Datei muss entsprechend $Anzahl-der-Pixel-der-Breite-des-Bildesx$Anzahl-der-Pixel-der-Hoehe-des-Bildes.$Endung-der-Datei-entsprechend-des-Typs-der-Datei verwendet werden.
Es kann auch ausreichen, das ein einziges Bild verwendet wird.
Erstellen der Datei für die Meta-Daten der Bilder für den Hintergrund metadata.desktop
(auf die Schelle das Einfachste)
$EDITOR /usr/local/share/wallpapers/PaulRiegel/metadata.desktop
Name=PaulRiegel
Name[de]=PaulRiegel
Name[x-test]=xxPaulRiegelxx
X-KDE-PluginInfo-Name=PaulRiegel
Ordner für das eigene Theme erstellen und bisher verwendetes (standardmäßiges) Theme übernehmen
einfach das Theme vom aktuellen Stand übernehmen
Bei mir was das übliche Oxygen.
cp -r /usr/local/share/apps/desktoptheme/oxygen /usr/local/share/apps/desktoptheme/PaulRiegel
oder
alternativ (und eigentlich kaum machbar) die Struktur entsprechend erstellen (und befüllen)
Erstellen der Datei für die Meta-Daten für das eigene Theme metadata.desktop
$EDITOR /usr/local/share/apps/desktoptheme/PaulRiegel/metadata.desktop
[Desktop Entry]
Name=PaulRiegel
Name[de]=PaulRiegel
Comment=Theme done in the Oxygen style and customized for PaulRiegel
Comment[de]=Oberflächen-Design im Oxygen-Stil und angepasst für PaulRiegel

X-KDE-PluginInfo-Author=PaulRiegel (copy of The Oxygen Project)
X-KDE-PluginInfo-Email=riegel@stura.htw-dresden.de
X-KDE-PluginInfo-Name=oxygen-als-PaulRiegel
X-KDE-PluginInfo-Version=0.01
X-KDE-PluginInfo-Website=http://www.stura.htw-dresden.de/members/PaulRiegel
X-KDE-PluginInfo-Category=
X-KDE-PluginInfo-Depends=
X-KDE-PluginInfo-License=GPL
X-KDE-PluginInfo-EnabledByDefault=true

[Wallpaper]
defaultWallpaperTheme=PaulRiegel
defaultFileSuffix=.png
defaultWidth=1280
defaultHeight=800

eigenes Theme im eigenen Verzeichnis ~ erstellen[Bearbeiten]

mkdir ~/customizing
mkdir -p ~/customizing/usr/local/share/apps/desktoptheme/`whoami`
cp -r /usr/local/share/apps/desktoptheme/oxygen/ ~/customizing/usr/local/share/apps/desktoptheme/`whoami`
cd ~/customizing/usr/local/share/apps/desktoptheme/`whoami`
  • Die Inhalte für desktoptheme entsprechend anpassen (siehe oben).
mkdir -p ~/customizing/usr/local/share/wallpapers/`whoami`
cp -r /usr/local/share/wallpapers/Elarun/ ~/customizing/usr/local/share/wallpapers/`whoami`
cd ~/customizing/usr/local/share/wallpapers/`whoami`
  • Die Inhalte für wallpapers entsprechend anpassen (siehe oben).
sudo ln -s ~/customizing/usr/local/share/wallpapers/`whoami` /usr/local/share/wallpapers/`whoami`
sudo ln -s ~/customizing/usr/local/share/apps/desktoptheme/`whoami` /usr/local/share/apps/desktoptheme/`whoami`

Lyx[Bearbeiten]

bei Lyx fehlen die Dokumentenklassen für LaTeX[Bearbeiten]

Für kein Dokument waren die grundsätzlichen Dokumentenklassen für LaTeX nicht verfügbar. Nachdem sichergestellt war, dass LaTeX verfügbar ist (Installation und Verwendung von kile), Werkzeuge -> Neu konfigurieren gestartet. Entsprechende des Hinweises (Das System wurde neu konfiguriert.Sie müssen LyX neu starten, um die aktualisierten Spezifikationen für die Dokumentklassen zu nutzen.), Lyx geschlossen und neu gestartet. Nun waren (nahezu) alle Dokumentenklassen verfügbar.

pbi[Bearbeiten]

PC-BSD
  • pcbsd-base
  • pcbsd-i18n
muss
  • firefox
    • firefox-i18n
  • thunderbird
    • thunderbird-i18n
  • pidgin
    • pidgin-otr
  • libreoffice | openoffice
soll
  • kde
    • gtk-qt-engine
      siehe systemsetting
    • (gtk-oxygen-engine)
    • (gtk3-oxygen-engine)
    • en-hunspell
    • de-hunspell
    • pcbsd-meta-kde
  • zsh
  • texlive-base
  • lyx
  • chromium
  • vlc
  • tox
    • utox
  • gimp
kann
  • dia
  • fish
  • (git)
  • hs-pandoc
  • kile
  • kports
  • (paprefs)
  • (pavucontrol)
  • padevchooser
  • pavumeter
  • qgit
  • semantik
  • tmux
darf
  • pxpkg
  • emacs
  • (gcc)
  • gobby
  • IcedTea-Web
    • OpenJDK
  • inkscape
  • mutt
  • wine | swine
  • texlive-full

foo[Bearbeiten]

/etc/sysctl.conf[Bearbeiten]

# Autodetect the most recent sound card. Uncomment for Digital output / USB
# hw.snd.default_auto=1
### "unit1" freigeschalten 2012-04-26, um den Sound vom X200 zu ermöglichen
hw.snd.default_unit=1
###
### Test wegen suspend to ram
#### gemaess http://grigorovl.com/freebsd/freebsd-8-1-on-thinkpad-x60/
# hw.acpi.reset_video=1
# hw.acpi.power_button_state=S5
# hw.acpi.verbose=1
# hw.syscons.sc_no_suspend_vtswitch=0
# dev.acpi_ibm.0.events=1
###

life-preserver[Bearbeiten]

manuell viele Snapshots löschen[Bearbeiten]

Dank life-preserver können (einfach automatisierte) Snapshots gemacht werden. Das Entfernen ist jedoch nur für jeden einzelnen Snapshot möglich. Jedoch kann es sein, dass eine Vielzahl von automatisch erstellen Snapshots entfernt werden sollen, etwa wenn Platz auf dem Massenspeicher gebraucht wird.

(optionales) Auflisten lassen von allen bestehenden Snapshots

zfs list -t snapshot

Entfernen (Zerstören) von allen Snapshots vom letzten Kalendermonat (-1m)

zfs list -H -t snapshot | grep `date -v-1m "+%Y-%m-"` | awk '{print $1}' | xargs -L 1 zfs destroy
alternativ das Entfernen (Zerstören) von allen Snapshots mit der Bezeichnung auto (was auch alle Snapshots beinhaltet, die von life-preserver automatisch erstellte)
zfs list -H -t snapshot | grep auto | awk '{print $1}' | xargs -L 1 zfs destroy

(optionales) Anzeigen lassen von freien Speicherplatz

df -h

update 10.1-RELEASE-p17[Bearbeiten]

Exemplarische Dokumentation der Vorgänge bei ZFS beim update (Erstellung von einem neuen boot environment)

sudo zpool history
2015-03-03.02:57:10 zfs destroy -r pesttank/ROOT/10.1-RELEASE-p16-up-20150210_112650
2015-03-03.02:57:15 zfs destroy pesttank/ROOT/10.1-RELEASE-p17-up-20150226_185320@2015-02-17-18:38:27
2015-03-03.02:57:37 zfs snapshot -r pesttank/ROOT/10.1-RELEASE-p17-up-20150226_185320@2015-03-03-02:57:36
2015-03-03.02:57:42 zfs clone -o canmount=off -o atime=off -o compression=lz4 -o mountpoint=/ pesttank/ROOT/10.1-RELEASE-p17-up-20150226_185320@2015-03-03-02:57:36 pesttank/ROOT/pcupdatestage
2015-03-03.04:04:11 zfs rename pesttank/ROOT/pcupdatestage pesttank/ROOT/10.1-RELEASE-p17-up-20150303_040409
2015-03-03.04:04:11 zfs set canmount=noauto pesttank/ROOT/10.1-RELEASE-p17-up-20150303_040409
2015-03-03.04:04:11 zfs set mountpoint=/tmp/BE-10.1-RELEASE-p17-up-20150303_040409.0TBIfyvs pesttank/ROOT/10.1-RELEASE-p17-up-20150303_040409
2015-03-03.04:04:12 zfs set mountpoint=/ pesttank/ROOT/10.1-RELEASE-p17-up-20150303_040409
2015-03-03.04:04:12 zpool set bootfs=pesttank/ROOT/10.1-RELEASE-p17-up-20150303_040409 pesttank
2015-03-03.04:04:13 zfs set canmount=noauto pesttank/ROOT/10.1-RELEASE-p16-up-20150217_184017
2015-03-03.04:04:13 zfs set canmount=noauto pesttank/ROOT/10.1-RELEASE-p16-up-20150222_062701
2015-03-03.04:04:13 zfs set canmount=noauto pesttank/ROOT/10.1-RELEASE-p17-up-20150226_185320
2015-03-03.04:04:14 zfs set canmount=noauto pesttank/ROOT/10.1-RELEASE-p17-up-20150303_040409
2015-03-03.04:04:16 zfs promote pesttank/ROOT/10.1-RELEASE-p17-up-20150303_040409

Thunderbird[Bearbeiten]

Verwendung passender Zeichensätze bei Thunderbird[Bearbeiten]

about
config

mailnews.view_default_charset

ISO-8859-1

mailnews.send_default_charset

UTF-8

intl.charsetmenu.mailview.cache

UTF-8, ISO-8859-1, ISO-8859-15, windows-1252

Format der Anzeige des Datums bei Thunderbird[Bearbeiten]

eigentlich:

"uneigentlich" (praktisch geht das auch über ein Addon)

zsh[Bearbeiten]

auf zsh, statt csh, für einen einzelnen Account umstellen
  • per Klicki-Bunti
oder
  • klassisch per Kommando
    chsh -s /usr/local/bin/zsh

zum Kontrollieren eine Ausgabe erwarten

cat /etc/passwd | grep `whoami` | echo $SHELL | grep zsh
oh-my-zsh "installieren"

oh-my-zsh als Skript von Github installieren (lassen)

sh -c "$(curl -fsSL https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"
oder alternativ im Stil von FreeBSD (ohne curl oder wget, sondern mit fetch)
cd /tmp ; fetch https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh ; sh -c "`cat /tmp/install.sh`" ; rm install.sh ; cd -

allgemeine Einstellungen[Bearbeiten]

grundsätzliche Einstellungen für das System[Bearbeiten]

cat ~/.profile

mirroring[Bearbeiten]

Benutzer Diskussion:PaulRiegel/TrueOS#mirroring

SWAP[Bearbeiten]

wir nehmen an, dass das Gerät (für Massenspeicher) /dev/ada0 ist

wir versuchen es gleich einmal richtig (mit dem labeling) zu machen, um probleme - welches gerät erhält welche forlaufende nummer - zu vermeiden.
gpart show

gpart destroy /dev/ada0
gpart create -s MBR /dev/ada0
gpart create -s GPT /dev/ada0
gpart add -t freebsd-swap -l swap /dev/ada0
gpart add -t freebsd-swap /dev/ada0

glabel status

newfs -L swap /dev/ada0

tunefs -L swap /dev/ada0

glabel label swap /dev/ada0
swapon /dev/label/swap
$EDITOR /etc/fstab
procfs                  /proc                   procfs          rw      0       0
linprocfs               /compat/linux/proc      linprocfs       rw      0       0
/dev/label/efibsd       /boot/efi               msdosfs         rw      0       0
/dev/label/swap         none                    swap            sw      0       0
glabel status

glabel list

glabel destroy swap