FTP my backups off of NAgios server

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
benningtonr
Posts: 524
Joined: Tue May 22, 2012 2:16 pm

FTP my backups off of NAgios server

Post by benningtonr »

I am trying to use ftp to copy my backup off of Nagios, but it keeps failing to list a dir.

I have this in the Firewall:
#FTP
-A INPUT -p tcp -m state --state NEW -m tcp --dport 20 -j ACCEPT
-A INPUT -p tcp -m state --state NEW -m tcp --dport 21 -j ACCEPT

but to no availe
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: FTP my backups off of NAgios server

Post by abrist »

Is the ftpd service running?
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
benningtonr
Posts: 524
Joined: Tue May 22, 2012 2:16 pm

Re: FTP my backups off of NAgios server

Post by benningtonr »

[root@nagios ~]# service vsftpd start
Starting vsftpd for vsftpd: [FAILED]
[root@nagios ~]#

It will not start, after i installed i just assumed it started

[root@nagios ~]# yum -y install vsftpd
Loaded plugins: fastestmirror
Determining fastest mirrors
epel/metalink | 9.0 kB 00:00
* base: mirror.umd.edu
* epel: mirror.vcu.edu
* extras: mirror.beyondhosting.net
* rpmforge: mirror.rit.edu
* updates: mirror.cs.uwp.edu
base | 3.7 kB 00:00
base/primary_db | 3.5 MB 00:00
cr | 2.9 kB 00:00
epel | 4.2 kB 00:00
epel/primary_db | 4.8 MB 00:04
extras | 3.4 kB 00:00
extras/primary_db | 18 kB 00:00
rpmforge | 1.9 kB 00:00
rpmforge/primary_db | 2.8 MB 00:00
updates | 3.4 kB 00:00
updates/primary_db | 1.3 MB 00:00
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package vsftpd.i686 0:2.2.2-11.el6_4.1 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

================================================================================
Package Arch Version Repository Size
================================================================================
Installing:
vsftpd i686 2.2.2-11.el6_4.1 base 157 k

Transaction Summary
================================================================================
Install 1 Package(s)

Total download size: 157 k
Installed size: 344 k
Downloading Packages:
vsftpd-2.2.2-11.el6_4.1.i686.rpm | 157 kB 00:00
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
Installing : vsftpd-2.2.2-11.el6_4.1.i686 1/1

Installed:
vsftpd.i686 0:2.2.2-11.el6_4.1

Complete!
[root@nagios ~]# chkconfig vsftpd on
[root@nagios ~]# service vsftpd start
Starting vsftpd for vsftpd: [ OK ]
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: FTP my backups off of NAgios server

Post by abrist »

Is it starting now, or still no go? Have you configured the ftp server?
https://www.digitalocean.com/community/ ... entos-6--2
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
benningtonr
Posts: 524
Joined: Tue May 22, 2012 2:16 pm

Re: FTP my backups off of NAgios server

Post by benningtonr »

It is starting:
[root@nagios ~]# service vsftpd restart
Shutting down vsftpd: [ OK ]
Starting vsftpd for vsftpd: [ OK ]
[root@nagios ~]#
[root@nagios ~]#


but still states:
Error: Connection timed out
Error: Failed to retrieve directory listing
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: FTP my backups off of NAgios server

Post by abrist »

Is the port open?

Code: Select all

nmap localhost -p 21
Did you configure the ftp server yet? If so, could you post the config (sanitize sensitive info)?
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
benningtonr
Posts: 524
Joined: Tue May 22, 2012 2:16 pm

Re: FTP my backups off of NAgios server

Post by benningtonr »

have not configured anything on the ftp

[root@nagios ~]# nmap localhost -p 21

Starting Nmap 5.21 ( http://nmap.org ) at 2014-01-27 14:01 EST
Nmap scan report for localhost (127.0.0.1)
Host is up (0.000065s latency).
Hostname localhost resolves to 2 IPs. Only scanned 127.0.0.1
rDNS record for 127.0.0.1: localhost.localdomain
PORT STATE SERVICE
21/tcp open ftp

Nmap done: 1 IP address (1 host up) scanned in 0.09 seconds
[root@nagios ~]#
sreinhardt
-fno-stack-protector
Posts: 4366
Joined: Mon Nov 19, 2012 12:10 pm

Re: FTP my backups off of NAgios server

Post by sreinhardt »

You might have to allow your iptables rules to include established connections as well as new. nmap and your service output do seem to show its otherwise working properly.
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
benningtonr
Posts: 524
Joined: Tue May 22, 2012 2:16 pm

Re: FTP my backups off of NAgios server

Post by benningtonr »

for what ever reason, it is connecting, but then saying there is no directory.
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: FTP my backups off of NAgios server

Post by abrist »

Any errors in the logs:

Code: Select all

tail -25 /var/log/vsftpd.log
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
Locked