Store2 Wiki:Portal: Unterschied zwischen den Versionen

Aus Store2 Wiki
Zur Navigation springen Zur Suche springen
imported>WikiSysop
Keine Bearbeitungszusammenfassung
 
Zeile 1: Zeile 1:
= SVN Subversion =
= Subversion =
'''Repository anlegen:'''
svnadmin create /data/svn/repos/newrepos
'''Initialer Import:'''
svn import /code/mycode file:///data/svn/repos/newrepos -m "Initial import"
dabei sollte das Verzeichniss /code/mycode die Unterverzeichnisse "'''branches tags trunk'''" enthalten.
'''Repo auschecken:'''
svn co svn+ssh://user@server/subversion/repos/myrepos
Beispiel:
svn co svn+ssh://moerchel@wolf.physik.uni-wuerzburg.de/q/home/moerchel/subversion/repos/matlab/trunk/ .
'''Änderungen lokal:'''
svn diff
'''Änderungen repos:'''
svn di svn+ssh://user@server/subversion/repos/myrepos
'''Änderungen hochladen:'''
svn ci svn+ssh://user@server/subversion/repos/myrepos
'''Alternativen Port einstellen:'''
in ~/.subversion/config
You'd think that the story of SSH tunneling would end here, but it doesn't. Subversion allows you to create custom tunnel behaviors in your run-time config file (see the section called “Runtime Configuration Area”). For example, suppose you want to use RSH instead of SSH[43]. In the [tunnels] section of your config file, simply define it like this:
[tunnels]
rsh = rsh
And now, you can use this new tunnel definition by using a URL scheme that matches the name of your new variable: svn+rsh://host/path. When using the new URL scheme, the Subversion client will actually be running the command rsh host svnserve -t behind the scenes. If you include a username in the URL (for example, svn+rsh://username@host/path) the client will also include that in its command (rsh username@host svnserve -t). But you can define new tunneling schemes to be much more clever than that:
[tunnels]
joessh = $JOESSH /opt/alternate/ssh -p 29934
This example demonstrates a couple of things. First, it shows how to make the Subversion client launch a very specific tunneling binary (the one located at /opt/alternate/ssh) with specific options. In this case, accessing a svn+joessh:// URL would invoke the particular SSH binary with -p 29934 as arguments—useful if you want the tunnel program to connect to a non-standard port.
= Raid-Status =
= Raid-Status =



Aktuelle Version vom 17. August 2010, 13:30 Uhr

SVN Subversion

Subversion

Repository anlegen:

svnadmin create /data/svn/repos/newrepos

Initialer Import:

svn import /code/mycode file:///data/svn/repos/newrepos -m "Initial import"

dabei sollte das Verzeichniss /code/mycode die Unterverzeichnisse "branches tags trunk" enthalten.

Repo auschecken:

svn co svn+ssh://user@server/subversion/repos/myrepos

Beispiel:

svn co svn+ssh://moerchel@wolf.physik.uni-wuerzburg.de/q/home/moerchel/subversion/repos/matlab/trunk/ .

Änderungen lokal:

svn diff

Änderungen repos:

svn di svn+ssh://user@server/subversion/repos/myrepos

Änderungen hochladen:

svn ci svn+ssh://user@server/subversion/repos/myrepos


Alternativen Port einstellen:

in ~/.subversion/config

You'd think that the story of SSH tunneling would end here, but it doesn't. Subversion allows you to create custom tunnel behaviors in your run-time config file (see the section called “Runtime Configuration Area”). For example, suppose you want to use RSH instead of SSH[43]. In the [tunnels] section of your config file, simply define it like this:

[tunnels]
rsh = rsh

And now, you can use this new tunnel definition by using a URL scheme that matches the name of your new variable: svn+rsh://host/path. When using the new URL scheme, the Subversion client will actually be running the command rsh host svnserve -t behind the scenes. If you include a username in the URL (for example, svn+rsh://username@host/path) the client will also include that in its command (rsh username@host svnserve -t). But you can define new tunneling schemes to be much more clever than that:

[tunnels]
joessh = $JOESSH /opt/alternate/ssh -p 29934

This example demonstrates a couple of things. First, it shows how to make the Subversion client launch a very specific tunneling binary (the one located at /opt/alternate/ssh) with specific options. In this case, accessing a svn+joessh:// URL would invoke the particular SSH binary with -p 29934 as arguments—useful if you want the tunnel program to connect to a non-standard port.

Raid-Status

mdadm --detail /dev/md127

Raid-Baustatus

cat /proc/mdstat

Raidgröße

1000000000000

als ext3


auch als ext3

Raid Baubefehl

mdadm --create /dev/md127 --level=raid6 --raid-devices=5 /dev/sdb1 /dev/sdc1 /dev/sdd1 /dev/sde1 /dev/sdf1 
mdadm --create /dev/md127 --chunk=64 --level=raid6 --layout=ls --raid-devices=5 /dev/sdb1 /dev/sdc1 /dev/sdd1 /dev/sde1 /dev/sdf1 

Verschlüssel von Hand (ohne Yast2)

Verschlüsseln:

cryptsetup -v --key-size 256 luksFormat /dev/md127 

Öffnen:

cryptsetup luksOpen /dev/md127 cr_md127 

Filesystem drauf:

mkfs.reiserfs /dev/mapper/cr_md127 

Status:

cryptsetup luksDump /dev/md127

Grown

yast2, neue Primärpartition mit Größe : 1000000000000 als Linux RAID, nicht formatieren oder einhängen
mdadm --add /dev/md127 /dev/sdg1
mdadm --grow --raid-devices=6 /dev/md127 --backup-file=/home/gagi/mda127backup

um zu sehen, wer/was gerade Zugriff nimmt:

lsof /data 

Unmounten:

umount /data 

Filesystem überprüfen:

reiserfsck --check /dev/mapper/cr_md127 

(Falls nötig, mit dm_crypt öffnen:)

(cryptsetup luksOpen /dev/md127 cr_md127)

Verschlüsselten Container wachsen:

cryptsetup --verbose resize cr_md127

Reiser-Filesystem wachsen:

resize_reiserfs /dev/mapper/cr_md127

Filesystem überprüfen:

reiserfsck --check /dev/mapper/cr_md127

Mounten:

mount /dev/mapper/cr_md127 /data

Read-Only Mounten:

mount -o ro /dev/mapper/cr_md127 /data

Mounten über Samba

mount //192.168.0.1/alte_Q /mnt

Subversion

Repository anlegen:

svnadmin create /data/svn/repos/newrepos

Initialer Import:

svn import /code/mycode file:///data/svn/repos/newrepos -m "Initial import"

dabei sollte das Verzeichniss /code/mycode die Unterverzeichnisse "branches tags trunk" enthalten.

Repo auschecken:

svn co svn+ssh://user@server/subversion/repos/myrepos

Änderungen lokal:

svn diff

Änderungen repos:

svn di svn+ssh://user@server/subversion/repos/myrepos

Änderungen hochladen:

svn ci svn+ssh://user@server/subversion/repos/myrepos

Webzugang von Außen

in /srv/www/htdocs .htaccess

darin nur den genutzten IPs Zugang erlauben.

Neuer Webuser

htdigest2 /srv/www/.htdigest Store gagihawaii

Webseite verändern

in /srv/www/htdocs/index.template verändern/anpassen

bzw. in /usr/local/bin/update_http.sh Parameter optimieren

dann

/usr/local/bin/update_http.sh

Locate auf Data/Data2

locate -i -d /data/locatedb "mein suchbegriff"

USB-Device mounten

mount -t ntfs-3g /dev/sdj5 /usb -o force

Store-Webseite ändern

Script unter

/usr/locale/bin/update_http.sh


Opensuse: IP über DHCP erneuern

  1.  Open a terminal and su - to root.
  2. Type ifconfig to show the current IP address that you received from DHCP.
  3. Type dhcpcd -k to send the appropriate signals to dhcpcd.
  4. Now bring the interface back up by typing ifup eth0.
  5. Type ifconfig to show the new IP address.

System-Backup-Image von USB-Platte mounten

mount -o loop /media/Data5/store_root.img /mnt/loop/

RAID6 aufblasen auf 1,5TB

Software-Raid-Dienst unster OpenSuse starten:

/etc/init.d/boot.md start 

0. UUID kaputt machen und Partitionstabelle zerstören für 1TB Platteninhalt dd-t auf 1,5TB Platte

dd if=/dev/zero bs=1024 count=2000 of=/dev/sdi

1. Farbikneue Festplatten über MB-SATA-Anschluss in Opensuse mit Partition (komplette Platte) und Filesystem (RAID) versehen

Dann für jede Platte sukzessive:

2. Platte failed setzen und aus Raidverbund rausnehmen:

 mdadm --set-faulty /dev/md127 /dev/sdo1
 mdadm --remove /dev/md127 /dev/sdo1

3. Plattenpartition maximiert (komplette Platte) mit Yast2 -> Partitioner neu anlegen (formatieren nicht nötig) -> Dieser Schritt DOCH nötig! -> Legacy

4. Wieder ins Raid reinnehmen

 mdadm --add /dev/md127 /dev/sdo
 

5. Bauen lassen

6. Nächste Platte

7. Wenn die 5 1TB-Platten "befreit" sind, aus denen ein neues Raid5 aufsetzen (siehe Anleitung) und darauf das alte Raid5 verschieben.

8. Wenn alle 14 1,5TB Platten im Raid6 sind, dann das Raid6 grown lassen

mdadm --grow /dev/md127 --size=max

9. Unmounten, Filesystem-Check, Cryptcontainer wachsen, ReiserFS wachsen (wie sonst auch, siehe oben).

RAID Layout mit Serials

01  : 1SWX1JSK292519 (1.5T)
02  : 1S6Y1JSK175967 (1.5T)
03  : 1S6Y1JSK175957 (1.5T)
04  : WD-WCAU40406122 (1.0T)
05  : 9VS0CVSE (1.5T)
06  : WD-WCAU40497763 (1.0T)
07  : 1SWX1JSK292509 (1.5T) 

08  : 9VS0CTFS (1.5T)
09  : 9VS0CWXA (1.5T)
10  : 9VS0HDNS (1.5T)
11  : W_-DCWUA54200342 (1.0T)
12  : W_-DCWUA54003755 (1.0T)
13  : 1SP31JQM041080 (1.0T)
14  : V91S44W6 (1.5T)
15  : WD-WMAM9DKR6107 (80G)

-------------------------------------------

16  :
17  :
18  :
19  :
20  :
21  :
22  :

23  : 1SWX1JSK2C4853 (1.5T)
24  : 1SWX1JSK2C4814 (1.5T)
25  : 1SWX1JSL0C9558 (1.5T)
26  :
27  : 1SWX1JSL0C1584 (1.5T)
28  : 1SWX1JSL0C0615 (1.5T)
29  :
30  :

Serials auslesen

Für RAID-Stauts einer einzelnen Platte:

mdadm --examine /dev/sdi

Zum Serial auslesen:

udevadm info --query=all --name=/dev/sdi

bzw.

udevadm info --query=all --name=/dev/sdi | grep ID_SERIAL_SHORT

HPT RAID Managment Server

läuft auf Port 7402 (wegen Putty SSH Tunnel und so)

Login: RAID

Pass: hpt

Manuel RPM Pakete installieren

rpm -ihv nedit-5.5-31.8.x86_64.rpm