individual ssh/sftp chroot

Author: Stephan  |  Category: Linux, Netzwerk

No execute or writepermissioms for the rest of the system is very simple on a linux system. To prevent , that a user, that only needs to upload files as an example, can see the rest of the system is a little bit more difficult.

One Solution:
We have a user named kunde.
We add a group sftpuser. Kunde became member of sftpuser.

We change
Subsystem sftp /usr/lib/openssh/sftp-server

in /etc/ssh/sshd.conf to
Subsystem sftp internal-sftp
and add

Match Group sftpuser
ChrootDirectory %h
ForceCommand internal-sftp

Then the ftpuser get an new home. Only root had write permissions

drwxr-xr-x 4 root root 4096 May 16 15:54 ftphome

For the individuap home , you need these permssions
drwxr-xr-x 2 kunde sftpuser 4096 May 16 15:52 kunde

Restart sshd
Thats all

Apache2piwik Howto

Author: Stephan  |  Category: Linux, Netzwerk

Ausgegangen bin ich von
http://piwik.org/blog/2011/06/import-log-files-piwik/
http://clearcode.cc/offer/open-source-projects/apache2piwik/

vom zweiten Link ist auch die Source zu beziehen
Voraussetzungen

neben einem funktionierenden python2.6 und einer funktionierenden piwik installation
ActivePython

wget http://downloads.activestate.com/ActivePython/releases/2.6.7.20/ActivePython-2.6.7.20-linux-x86.tar.gz
tar xzvf ActivePython-2.6.7.20-linux-x86.tar.gz
cd ActivePython-2.6.7.20-linux-x86/
./install.sh

Setuptools

wget http://pypi.python.org/packages/source/s/setuptools/setuptools-0.6c11.tar.gz
tar xzvf setuptools-0.6c11.tar.gz
cd setuptools-0.6c11
python2.6 setup.py install

http-Agent parser


cd httpagentparser-0.8.2/
/opt/ActivePython-2.6/bin/pypm install httpagentparser

pygeoip


wget http://pygeoip.googlecode.com/files/pygeoip-0.2.2.tar.gz
tar xzvf pygeoip-0.2.2.tar.gz
cd /usr/src/pygeoip-0.2.2/
python setup.py install

Einlesen der Logs

Bei mir hat das Einlesen aus directories nicht funktioniert, deswegen bin ich folgenden Weg gegangen


for i in `ls /root/old_logs/apache/` ; do python2.6 ./apache2piwik.py -f /root/old_logs/apache/$i ; done

howto name Areas in Excel/Calc

Author: Stephan  |  Category: Linux, Sonstiges, windows

A short tipp for Excel/Calc

Mark an area . Than you see at the left e.g. D4:D13 . Now you change D4:D13 into Testspalte in this Field.
Now Excel/Calc offers to integrate Testspalte into Formulas.

=SUMME(Testspalte)

version control ist not only for developers

Author: Stephan  |  Category: Linux, Sonstiges, windows

Who doesn’t know this:
“If I only had an old version of my bookmarks, my curriculum or another important office document”
This is the point to think about version control like developers use for Code.
One version control tool usable for this is git.
Git was developed by Linus Torvalds and others for the Linux Kernel but it also exist a windows version.
Lets make our first repository

cd mydir
git init
git add .
git commit

How track down Changes ?
git status
git diff

Commit History
git log
Howto revert the last commit
git revert HEAD

A useful link

https://git.wiki.kernel.org/index.php/GitCheatSheet

Nagios is checking the weather

Author: Stephan  |  Category: Linux, Nagios, Sonstiges

One of the more humorous uses of nagios is the possibility to check the weather.
This is the use of the plugin check_weather
nagiosplugins.org
Then you have to register at weather.com to use the webservice and get a userid and a license.
The userid and the license hat to put into check_weather.pl

my $weather = Weather::Com::Simple->new(
partner_id => "my ID",
license => "myLicense",

The result

/server/nagios/libexec > ./check_weather.pl -l neu-ulm
WEATHER OK - Temperature -11 degrees celsius at Neu-Ulm, Germany | celsius=-11;;

ftpsfs howto

Author: Stephan  |  Category: Linux, Netzwerk

I own a little NAS which was mounted as samba share. This was not always sucessfull so I was looking for another way.
There ist a very nice alternative by using curlftpfs
I need the packet curlftpfst ( dependencies to libfuse2 (FUSE=FileSystem in Userspace ))
After installing you can mount it very easily
curlftpfs -o nonempty admin:passwort@192.168.1.91/PUBLIC/ /mount/
or integrate it even into fstab
curlftpfs#admin:passwort@192.168.1.91 /mount fuse rw,uid=500,user,noauto 0 0

cygwin with sshd and windows 7

Author: Stephan  |  Category: Linux, Netzwerk, windows

What is cygwin ?
Cygwin is a set of tools to add POSIX compability to a Windows System. Imagine, you can grep and less and use vi and the Basic System is Windows system.
You can also install a sshd for remote access.

To install cygwin under windows7 , you need the newest release . I used version 1.7 , Beta but stable.

The installation dialog is similar to most linux distributions. Choose the packets you want but don’t forget the sshd.

After the installation is finished open a shell and do the following
ssh-host-config -y
When prompted with “CYGWIN=” type for following:
tty ntsec
Then you can start it with.
cygrunsrv -S sshd
Be shure that your Firewall accepts incomming ssh connections.

Wie Windowszeilenumbrüche unter Linux entfernen

Author: admin  |  Category: Linux

Unter DOS/Windows erstellte Dateien erscheinen unter GNU/Linux häufig mit doppelten Zeilenendezeichen, da auf diesen Systemen eine Kombination aus CR+LF verwendet wird. CR (Carriage Return) hat den ASCII-Code 13, LF (Line Feed) den ASCII-Code 10.

Um diese Dateien zu konvertieren, gibt es verschiedene Lösungsansätze. Im vi benutzt man das Kommando
:se ff=unix.
Sollten noch überflüssige RETURN-Zeichen (^M) am Zeilenende auftauchen, so lassen sich diese mittels
:1,$s/^M//g
entfernen. Dabei muss man das ^M durch Drücken von STRG+V, gefolgt von STRG+M, eingeben. STRG+V dient dazu, die nachfolgend gedrückte Tastenkombination direkt in den Text zu übernehmen.

More news by category Topic -: Buy phentermine saturday delivery ohio Tramadol hydrochloride tablets Picture of xanax pills Free shipping cheap phentermine Buying phentermine without prescription Safety of phentermine Pyridium Generic viagra cialis Cialis generic india Pink oval pill 17 xanax identification Buy free phentermine shipping Best price for generic viagra Information about street drugs or xanax bars Ordering viagra Snorting phentermine Hydrocodone overdose Lithium Amiodarone Get online viagra Order viagra prescription Order xanax paying cod Cheap phentermine free shipping Imiquimod Tramadol next day Linkdomain buy online viagra info domain buy onlin Pfizer viagra sperm Vidarabine Cheapest viagra price Prevacid Viagra cialis levitra comparison Dutasteride Lisinopril Thiotepa Female spray viagra Black market phentermine Betamethasone Cialis forums What does xanax look like Loss phentermine story success weight Order xanax overnight Viagra alternative uk Diet online phentermine pill Order xanax cod Mecamylamine Eulexin Cheap hydrocodone Buy cheapest viagra Viagra xenical Phentermine with no prior prescription Xanax in urine Macrodantin Cheap phentermine with online consultation Epivir Buy phentermine epharmacist Ditropan Woman use viagra Cialis erectile dysfunction Xanax withdrawl message boards Viagra online store Atorvastatin Generic ambien Is phentermine addictive Next day delivery on phentermine Buy online viagra Ethanol Natural phentermine Avandamet Xanax long term use Diet page phentermine pill yellow 5 cheap Cheapest secure delivery cialis uk Information medical phentermine Cialis experience Phentermine no perscription Compare ionamin phentermine Viagra cialis levivia dose comparison Noroxin Effects of viagra on women Buy cheap cialis Viagra shelf life Hydroxyurea Phentermine discount no prescription Buy cheap online viagra Dog xanax Online cialis Viagra class action Viagra price Phentermine without prescription and energy pill Hydrocodone cod only Nicoumalone Cheapest viagra Cheap ambien Vicodin without prescription Phentermine prescription online Phentermine snorting Mirtazapine Quazepam Isradipine Buy generic viagra online Xanax look alike Moxifloxacin Viagra experiences Piroxicam Nicorette Free try viagra Sotalol Cash on delivery shipping of phentermine How do i stop taking phentermine Xanax prescriptions Cheapest phentermine 90 day order Niacinamide Phentermine weight loss Phentermine