redhat:base-redhat:basics-redhat

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
redhat:base-redhat:basics-redhat [2018/08/14 17:03] – [Basis Know-How Redhat Systems] michaelredhat:base-redhat:basics-redhat [2019/06/11 10:24] (current) – [System Information] michael
Line 6: Line 6:
  
 ===== Basis Know-How Redhat Systems ===== ===== Basis Know-How Redhat Systems =====
 +
 +  * [[linux:user-and-groups|]]
 +  * [[linux:dateirechte|]]
 +
  
 <WRAP center box 100%> <WRAP center box 100%>
Line 11: Line 15:
 ''Grundlegende Systemwartung, durch Installation, von aktuellen Paketen und Upgraden des Kernels.'' ''Grundlegende Systemwartung, durch Installation, von aktuellen Paketen und Upgraden des Kernels.''
  
-<wrap em>Upgrade System and Packages:</wrap><code># yum -y update</code>+<wrap em>Upgrade System and Packages:</wrap><code># yum update -y</code>
 </WRAP> </WRAP>
  
Line 27: Line 31:
 ==== motd - Message of the day==== ==== motd - Message of the day====
 ''Eigene motd (Login-Nachricht), nach dem Aufbau einer neuen SSH-Verbindung anzeigen lassen:'' ''Eigene motd (Login-Nachricht), nach dem Aufbau einer neuen SSH-Verbindung anzeigen lassen:''
- 
-Add description and serial number to motd: 
  
 <code># echo ' <code># echo '
Line 64: Line 66:
 </WRAP> </WRAP>
  
 +<WRAP center box 100%>
 +==== Die Grösse eines Ordners anzeigen ====
 +''Zeigt die effektive Grösse - human readable und rekursiv über alle Files dar.''
 +<code># du -hs foswiki/</code>
 +<sxh plain; gutter: false;>4.6G    foswiki/</sxh>
 +
 +</WRAP>
  
 <WRAP center box 100%> <WRAP center box 100%>
Line 379: Line 388:
 </WRAP> </WRAP>
  
 +
 +<WRAP center box 100%>
 +==== Show what exactly a Package does on installation ====
 +''rpm -qp --scripts PACKAGENAME''
 +<code># rpm -qp --scripts patchman-1.0.20-1.noarch.rpm</code>
 +<sxh plain; gutter: false;>
 +postinstall scriptlet (using /bin/sh):
 +#!/bin/sh
 +
 +if [ ! -e /etc/httpd/conf.d/patchman.conf ] ; then
 +    cp /etc/patchman/apache.conf.example /etc/httpd/conf.d/patchman.conf
 +fi
 +
 +if ! grep /usr/lib/python2.7/site-packages /etc/httpd/conf.d/patchman.conf >/dev/null 2>&1 ; then
 +    sed -i -e "s/^\(Define patchman_pythonpath\).*/\1 \/usr\/lib\/python2.7\/site-packages/" \
 +    /etc/httpd/conf.d/patchman.conf
 +fi
 +
 +service httpd reload
 +
 +patchman-set-secret-key
 +chown apache /etc/patchman/local_settings.py
 +
 +mkdir -p /var/lib/patchman/db
 +patchman-manage collectstatic --noinput
 +
 +patchman-manage makemigrations
 +patchman-manage migrate --run-syncdb
 +
 +chown -R apache:apache /var/lib/patchman
 +chcon --type httpd_sys_rw_content_t /var/lib/patchman/db/patchman.db
 +
 +echo
 +echo "Remember to run 'patchman-manage createsuperuser' to create a user."
 +echo
 +</sxh>
 +</WRAP>
  
 ---- ----
  • redhat/base-redhat/basics-redhat.1534259025.txt.gz
  • Last modified: 2018/08/14 17:03
  • by michael