snipe / snipe-it

A free open source IT asset/license management system
https://snipeitapp.com
GNU Affero General Public License v3.0
11.17k stars 3.2k forks source link

Error 500 server on image upload #15827

Open rmdpereira opened 1 week ago

rmdpereira commented 1 week ago

Debug mode

Describe the bug

When creating a new accessory and uploading an image for it, once clicking save, Snipe immediately errors to 500 server error. The image loads prior to clicking save.

Saving the accessory without an image is successful. Going back and adding an image later also gives the 500 server error

Reproduction steps

1.Add new accessory 2.Upload image file 3.Click Save ...

Expected behavior

When adding an accessory, it's expected to allow an image upload and then a successful save.

Screenshots

No response

Snipe-IT Version

7.0.13

Operating System

Windows Server 2022 Standard

Web Server

IIS

PHP Version

8.1.30

Operating System

No response

Browser

No response

Version

No response

Device

No response

Operating System

No response

Browser

No response

Version

No response

Error messages

No response

Additional context

No response

welcome[bot] commented 1 week ago

👋 Thanks for opening your first issue here! If you're reporting a 🐞 bug, please make sure you include steps to reproduce it. We get a lot of issues on this repo, so please be patient and we will get back to you as soon as we can.

snipe commented 1 week ago

My guess would be that you don't have gd or imagemagik installed (though without seeing your logs, that's hard to determine), or that the permissions on the directories the files are uploaded to do not allow files to be written. Check permissions on your storage directory and all subfolders, and also your public/uploads directory and all subdirectories within it.

If you check your app log, it should show you the specific error message.

rmdpereira commented 1 week ago

This happened after migrating from snipeit 6.20 to 7.0.13. It was working before. This is not really my area. Where can I find the logs?

snipe commented 1 week ago

https://snipe-it.readme.io/docs/getting-help#step-3-check-your-app-and-server-logs

Snipe-IT Documentation
Getting Help
If you're having trouble setting up Snipe-IT, don't worry!