snipe-it icon indicating copy to clipboard operation
snipe-it copied to clipboard

GUI Backup Issue v5.0.11

Open namarie23 opened this issue 5 years ago • 3 comments

Please confirm you have done the following before posting your bug report:

Describe the bug A clear and concise description of what the bug is. The generate back up button in the GUI doesn't work , but php artisan backup:run does

To Reproduce Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior A clear and concise description of what you expected to happen. A successful GUI generated back up. Screenshots If applicable, add screenshots to help explain your problem. image image image

Server (please complete the following information):

  • Snipe-IT Version 5.0.11
  • OS: [e.g. Ubuntu, CentOS] Windows Server 2016
  • Web Server: [e.g. Apache, IIS] IIS
  • PHP Version 7.3.12

Desktop (please complete the following information):

  • OS: [e.g. iOS]
  • Browser [e.g. chrome, safari]
  • Version [e.g. 22]

Smartphone (please complete the following information):

  • Device: [e.g. iPhone6]
  • OS: [e.g. iOS8.1]
  • Browser [e.g. stock browser, safari]
  • Version [e.g. 22]

Error Messages

  • WITH DEBUG TURNED ON, if you're getting an error in your browser, include that error
  • If a stacktrace is provided in the error, include that too.
  • Any errors that appear in your browser's error console.
  • Confirm whether the error is reproducible on the demo: https://snipeitapp.com/demo.
  • Include any additional information you can find in storage/logs and your webserver's logs.
  • Include the output from php -m (this should display what modules you have enabled.)

Additional context

  • Is this a fresh install or an upgrade? Upgrade but the issue existed on the previous version too.
  • What OS and web server you're running Snipe-IT on Windows 2016 Server
  • What method you used to install Snipe-IT (install.sh, manual installation, docker, etc) Manual
  • Include what you've done so far in the installation, and if you got any error messages along the way. Checked the DB_Dump Path, verified the relevant folders had IUSR and IIS_IUSRS added with permissions.
  • Indicate whether or not you've manually edited any data directly in the database No.

Add any other context about the problem here.

Please do not post an issue without answering the related questions above. If you have opened a different issue and already answered these questions, answer them again, once for every ticket. It will be next to impossible for us to help you.

namarie23 avatar Dec 30 '20 23:12 namarie23

Hi @namarie23,

I think this is an issue on IIS that prematurely exits the process that is spun up on the request (snipe-it/SettingsController.php at master · snipe/snipe-it - L1056), unsure as to why.. I run Laragon with php 7.4 on my Windows machine and I am unable to reproduce unless I deliberately do it.

Can you make a new php file in the root of the directory of your Snipe-IT installation, paste the following content and then run it manually? Please, provide the output.

<?php

use Symfony\Component\Process\Process;

require_once __DIR__ . '/vendor/autoload.php';

$process = new Process('php -v');
$process->mustRun();
var_dump(
	$process->getOutput(), 
	$process->getErrorOutput(),
	shell_exec('php -v')
);

Should give you an output of the following:

$ php test.php
string(155) "PHP 7.4.12 (cli) (built: Oct 27 2020 17:18:47) ( ZTS Visual C++ 2017 x64 )
Copyright (c) The PHP Group
Zend Engine v3.4.0, Copyright (c) Zend Technologies
"
string(0) ""
string(155) "PHP 7.4.12 (cli) (built: Oct 27 2020 17:18:47) ( ZTS Visual C++ 2017 x64 )
Copyright (c) The PHP Group
Zend Engine v3.4.0, Copyright (c) Zend Technologies
"

Also curious if you get any php related errors in your IIS logs?

albinbatman avatar Dec 31 '20 01:12 albinbatman

Creating that file just yields a 500 error.

namarie23 avatar Jan 06 '21 21:01 namarie23

Creating that file just yields a 500 error.

You are supposed to run it in your terminal, not accessing it through your web browser.

albinbatman avatar Jan 06 '21 22:01 albinbatman