Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Copying zip failed because: Connection could not be established with host localhost [Connection refused #111]. #862

Closed
mrSam01 opened this issue Feb 14, 2019 · 1 comment

Comments

@mrSam01
Copy link

mrSam01 commented Feb 14, 2019

Hi pls help me with this issue.
Backups to driver 'dropbox' run successfully.
But If i run backup:run with driver 'localhost' in config i get this errors:

Copying zip failed because: Connection could not be established with host localhost [Connection refused #111].
Backup failed because Connection could not be established with host localhost [Connection refused #111].
#0 panel/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/StreamBuffer.php(58): Swift_Transport_StreamBuffer->establishSocketConnection()
#1 panel/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/AbstractSmtpTransport.php(143): Swift_Transport_StreamBuffer->initialize(Array)
#2 panel/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Mailer.php(65): Swift_Transport_AbstractSmtpTransport->start()
#3 panel/vendor/laravel/framework/src/Illuminate/Mail/Mailer.php(479): Swift_Mailer->send(Object(Swift_Message), Array)
#4 panel/vendor/laravel/framework/src/Illuminate/Mail/Mailer.php(259): Illuminate\Mail\Mailer->sendSwiftMessage(Object(Swift_Message))
#5 panel/vendor/laravel/framework/src/Illuminate/Notifications/Channels/MailChannel.php(65): Illuminate\Mail\Mailer->send(Object(Illuminate\Support\HtmlString), Array, Object(Closure))
#6 panel/vendor/laravel/framework/src/Illuminate/Notifications/NotificationSender.php(144): Illuminate\Notifications\Channels\MailChannel->send(Object(Spatie\Backup\Notifications\Notifiable), Object(Spatie\Backup\Notifications\Notifications\BackupHasFailed))
#7 panel/vendor/laravel/framework/src/Illuminate/Notifications/NotificationSender.php(103): Illuminate\Notifications\NotificationSender->sendToNotifiable(Object(Spatie\Backup\Notifications\Notifiable), '5938fa4b-b87f-4...', Object(Spatie\Backup\Notifications\Notifications\BackupHasFailed), 'mail')
#8 panel/vendor/laravel/framework/src/Illuminate/Support/Traits/Localizable.php(19): Illuminate\Notifications\NotificationSender->Illuminate\Notifications{closure}()
#9 panel/vendor/laravel/framework/src/Illuminate/Notifications/NotificationSender.php(105): Illuminate\Notifications\NotificationSender->withLocale(NULL, Object(Closure))
#10 panel/vendor/laravel/framework/src/Illuminate/Notifications/NotificationSender.php(77): Illuminate\Notifications\NotificationSender->sendNow(Array, Object(Spatie\Backup\Notifications\Notifications\BackupHasFailed))
#11 panel/vendor/laravel/framework/src/Illuminate/Notifications/ChannelManager.php(39): Illuminate\Notifications\NotificationSender->send(Array, Object(Spatie\Backup\Notifications\Notifications\BackupHasFailed))
#12 panel/vendor/laravel/framework/src/Illuminate/Notifications/RoutesNotifications.php(18): Illuminate\Notifications\ChannelManager->send(Object(Spatie\Backup\Notifications\Notifiable), Object(Spatie\Backup\Notifications\Notifications\BackupHasFailed))
#13 panel/vendor/spatie/laravel-backup/src/Notifications/EventHandler.php(33): Spatie\Backup\Notifications\Notifiable->notify(Object(Spatie\Backup\Notifications\Notifications\BackupHasFailed))
#14 panel/vendor/laravel/framework/src/Illuminate/Events/Dispatcher.php(360): Spatie\Backup\Notifications\EventHandler->Spatie\Backup\Notifications{closure}(Object(Spatie\Backup\Events\BackupHasFailed))
#15 panel/vendor/laravel/framework/src/Illuminate/Events/Dispatcher.php(209): Illuminate\Events\Dispatcher->Illuminate\Events{closure}('Spatie\Backup\E...', Array)
#16 panel/vendor/laravel/framework/src/Illuminate/Foundation/helpers.php(482): Illuminate\Events\Dispatcher->dispatch('Spatie\Backup\E...')
#17 panel/vendor/spatie/laravel-backup/src/Tasks/Backup/BackupJob.php(274): event(Object(Spatie\Backup\Events\BackupHasFailed))
#18 panel/vendor/spatie/laravel-backup/src/Tasks/Backup/BackupJob.php(266): Spatie\Backup\Tasks\Backup\BackupJob->sendNotification(Object(Spatie\Backup\Events\BackupHasFailed))
#19 panel/vendor/laravel/framework/src/Illuminate/Support/Collection.php(419): Spatie\Backup\Tasks\Backup\BackupJob->Spatie\Backup\Tasks\Backup{closure}(Object(Spatie\Backup\BackupDestination\BackupDestination), 0)
#20 panel/vendor/spatie/laravel-backup/src/Tasks/Backup/BackupJob.php(268): Illuminate\Support\Collection->each(Object(Closure))
#21 panel/vendor/spatie/laravel-backup/src/Tasks/Backup/BackupJob.php(150): Spatie\Backup\Tasks\Backup\BackupJob->copyToBackupDestinations('/var/www/panel...')
#22 panel/vendor/spatie/laravel-backup/src/Commands/BackupCommand.php(52): Spatie\Backup\Tasks\Backup\BackupJob->run()
#23 [internal function]: Spatie\Backup\Commands\BackupCommand->handle()
#24 panel/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php(29): call_user_func_array(Array, Array)
#25 panel/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php(87): Illuminate\Container\BoundMethod::Illuminate\Container{closure}()
#26 panel/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php(31): Illuminate\Container\BoundMethod::callBoundMethod(Object(Illuminate\Foundation\Application), Array, Object(Closure))
#27 panel/vendor/laravel/framework/src/Illuminate/Container/Container.php(572): Illuminate\Container\BoundMethod::call(Object(Illuminate\Foundation\Application), Array, Array, NULL)
#28 panel/vendor/laravel/framework/src/Illuminate/Console/Command.php(183): Illuminate\Container\Container->call(Array)
#29 panel/vendor/symfony/console/Command/Command.php(255): Illuminate\Console\Command->execute(Object(Symfony\Component\Console\Input\ArgvInput), Object(Illuminate\Console\OutputStyle))
#30 panel/vendor/laravel/framework/src/Illuminate/Console/Command.php(170): Symfony\Component\Console\Command\Command->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Illuminate\Console\OutputStyle))
#31 panel/vendor/spatie/laravel-backup/src/Commands/BaseCommand.php(16): Illuminate\Console\Command->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#32 panel/vendor/symfony/console/Application.php(901): Spatie\Backup\Commands\BaseCommand->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#33 panel/vendor/symfony/console/Application.php(262): Symfony\Component\Console\Application->doRunCommand(Object(Spatie\Backup\Commands\BackupCommand), Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#34 panel/vendor/symfony/console/Application.php(145): Symfony\Component\Console\Application->doRun(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#35 panel/vendor/laravel/framework/src/Illuminate/Console/Application.php(89): Symfony\Component\Console\Application->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#36 panel/vendor/laravel/framework/src/Illuminate/Foundation/Console/Kernel.php(122): Illuminate\Console\Application->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#37 panel/artisan(37): Illuminate\Foundation\Console\Kernel->handle(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#38 {main}
Backup failed because: Connection could not be established with host localhost [Connection refused #111].

Swift_TransportException : Connection could not be established with host localhost [Connection refused #111]

at panel/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/StreamBuffer.php:269
265| }
266| $streamContext = stream_context_create($options);
267| $this->stream = @stream_socket_client($host.':'.$this->params['port'], $errno, $errstr, $timeout, STREAM_CLIENT_CONNECT, $streamContext);
268| if (false === $this->stream) {

269| throw new Swift_TransportException(
270| 'Connection could not be established with host '.$this->params['host'].
271| ' ['.$errstr.' #'.$errno.']'
272| );
273| }

Exception trace:

1 Swift_Transport_StreamBuffer::establishSocketConnection()
panel/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/StreamBuffer.php:58

2 Swift_Transport_StreamBuffer::initialize()
panel/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/AbstractSmtpTransport.php:143

Please use the argument -v to see more details.

@mrSam01 mrSam01 closed this as completed Feb 14, 2019
@nysso
Copy link

nysso commented Apr 30, 2019

I have the same problem
how did you solve it ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants