Ftp EnableLogging

From QNAPedia
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

<multilang>

@de|Anbei wird erklärt wie man die eine Funktion in die proftpd.conf Datei einbindet, um die Verbindungslogs zu dokumentieren und über den Webserver auszugeben.


Vorraussetzungen

  • Sie müssen wissen wie man sich via ssh oder telnet (z.B. mit SSH PuTTY) auf das NAS verbindet
  • Sie müssen wissen wie man Dateien mit dem Editor #vi bearbeitet oder wie man via SFTP (z.B. mit WinSCP) Dateien bearbeitet

Anleitung

  1. Verbinden Sie sich mit SSH oder Telnet auf Ihren Qnap Gerätz.B. mit Putty
  2. Erstellen Sie mit
    # mkdir /share/HDA_DATA/Qweb/ftplogs/
    ein neues Verzeichnis names "ftplogs".
  3. Bearbeiten Sie die Konfigdatei mit
    # vi /mnt/HDA_ROOT/.config/proftpd.conf
  4. Ändern der proftpd.conf Einträge
    1. TransferLog None
      in
      TransferLog /share/HDA_DATA/Qweb/ftplogs/xferlog
    2. Fügen Sie nach TransferLog in der nächsten Zeile folgendes ein.
      LogFormat userlog "%u %b"
      ExtendedLog /share/HDA_DATA/Qweb/ftplogs/bytes WRITE,READ userlog
  5. Verlassen Sie den Bearbeitungsmodus mit: ESC
  6. Speichern und verlassen: drücke ZZ
  7. Führen Sie folgendes Kommando aus
    #/etc/init.d/ftp.sh reconfig


Allgemeine Tipps: Bei aktivierten Webserver kann nun über http://NAS-IP/ftplogs/bytes oder http://NAS-IP/ftplogs/xferlog die entsprechende Logdatei im Browser eingesehen werden.


Siehe www.proftpd.de.
Deutsches Qnap Forum www.qnapclub.de.

@en|These are instructions on how to enable logging on the proftp server on your QNAP.


Requirements

  • You must know how to connect to your QNAP using either ssh or telnet
  • A basic knowledge of vi editor #vi

Instructions

  1. Connect to your QNAP using SSH or Telnet
  2. Create a new directory called "ftplogs" using this command
    # mkdir /share/HDA_DATA/Qweb/ftplogs/
  3. Edit the ftp config file using vi like this
    # vi /mnt/HDA_ROOT/.config/proftpd.conf
    1. Press i to enter Insert mode and edit this entry:
      TransferLog None
      to
      TransferLog /share/HDA_DATA/Qweb/ftplogs/xferlog
    2. Insert these entries below the line you just edited
      LogFormat userlog "%u %b"
      ExtendedLog /share/HDA_DATA/Qweb/ftplogs/bytes WRITE,READ userlog
  4. Exit the Edit Mode by pressing ESC
  5. To Save and Exit, press ZZ
  6. Back at the command prompt, type
    #/etc/init.d/ftp.sh reconfig
    to re-initialise the ftp server.


General Tips: You should now be able to view the logs in your browser using http://NAS-IP/ftplogs/bytes or http://NAS-IP/ftplogs/xferlog .


See www.proftpd.de.
Deutsches Qnap Forum www.qnapclub.de.
Translated from the German article.

</multilang>