Debian Server · SSH + FTP

Konfiguracja SSH + FTP

Pełny poradnik uruchomienia zdalnego dostępu i transferu plików

🔐 1. SSH – zdalny dostęp do serwera

Instalacja SSH
apt update apt install openssh-server -y systemctl enable ssh systemctl start ssh
🌐 SSH pozwala sterować serwerem z innego komputera (np. PuTTY, terminal).
Sprawdzenie działania
root@debian:~$ systemctl status ssh
● ssh.service - active (running)
Logowanie
nano /etc/ssh/sshd_config - PermitRootLogin yes

📁 2. FTP – przesyłanie plików

Instalacja vsftpd
apt update apt install vsftpd -y
Uruchomienie usługi
systemctl enable vsftpd systemctl start vsftpd
📡 FTP umożliwia wysyłanie i pobieranie plików z serwera.
Konfiguracja
nano /etc/vsftpd.conf
Włącz opcje
write_enable=YES local_enable=YES
Restart FTP
systemctl restart vsftpd

⚠️ 3. Porty serwera

SSH → 22 FTP → 21 SFTP → 22 (przez SSH) HTTP → 80 HTTPS → 443
🔥 Jeśli nie działa — sprawdź firewall (ufw / iptables).