Ampache doesn't install correctly - running DietPi v6.28.0 on RPi B (armv6l) Topic is solved

Having issues with your DietPi installation, or, found a bug? Post it here.
Post Reply
edajai
Posts: 3
Joined: Sun Mar 15, 2020 9:42 pm

Ampache doesn't install correctly - running DietPi v6.28.0 on RPi B (armv6l)

Post by edajai »

I've installed Ampache using dietpi-software without errors. But when i visit the page "http://ipaddress/ampache" I end up on a page that throws the following error:
__________________________________________
Error

You may have reached this page because Ampache was unable to load the required dependencies

Please visit the wiki for help
__________________________________________

The url "http://ipaddress/ampache/test.php" also redirects to the above error page
User avatar
Joulinar
Posts: 2023
Joined: Sat Nov 16, 2019 12:49 am

Re: Ampache doesn't install correctly - running DietPi v6.28.0 on RPi B (armv6l)

Post by Joulinar »

Hi,

I tried to verify the issue and installed it on my Demo VM. During installation I have seen some error message

Code: Select all

  Failed to download dropbox/dropbox-sdk from source: Failed to clone https://github.com/dropbox/dropbox-sdk-php.git via https, ssh protocols, aborting.

- https://github.com/dropbox/dropbox-sdk-php.git
  Cloning into '/var/www/ampache/lib/vendor/dropbox/dropbox-sdk'...
  remote: Invalid username or password.
  fatal: Authentication failed for 'https://github.com/dropbox/dropbox-sdk-php.git/'

- git@github.com:dropbox/dropbox-sdk-php.git
  Cloning into '/var/www/ampache/lib/vendor/dropbox/dropbox-sdk'...
  error: cannot run ssh: No such file or directory
  fatal: unable to fork

    Now trying to download from dist
  - Installing dropbox/dropbox-sdk (v1.1.7): Downloading (failed)

  [Composer\Downloader\TransportException]
  The "https://api.github.com/repos/dropbox/dropbox-sdk-php/zipball/0f1a178ca9c0271bca6426dde8f5a2241578deae" file could not be downloaded (HTTP/1.1
  404 Not Found)
looks like some issues with source software package.

EDIT:
I tried to install it according ampache instructions and it fails at the same point during Composer steps. So it's definitely something wrong at ampache side.

https://github.com/ampache/ampache/wiki ... requisites

I created a bug report at ampache
https://github.com/ampache/ampache/issues/2332
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
edajai
Posts: 3
Joined: Sun Mar 15, 2020 9:42 pm

Re: Ampache doesn't install correctly - running DietPi v6.28.0 on RPi B (armv6l)

Post by edajai »

Maybe the following details might help:

I enable logging under ampache. This is what the log file says:

Code: Select all

2020-03-16 12:24:17 [ampache] (core.class) -> 'Gettext\Translations' not found!
User avatar
Joulinar
Posts: 2023
Joined: Sat Nov 16, 2019 12:49 am

Re: Ampache doesn't install correctly - running DietPi v6.28.0 on RPi B (armv6l)

Post by Joulinar »

Hi,

no need to further investigate it at our side. This is an Ampache issue and would need to be fixed by Ampache developer.

You can follow this at GitHub https://github.com/ampache/ampache/issues/2332
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
User avatar
Joulinar
Posts: 2023
Joined: Sat Nov 16, 2019 12:49 am

Re: Ampache doesn't install correctly - running DietPi v6.28.0 on RPi B (armv6l)

Post by Joulinar »

Hi,

here you go with the small guide to implement the hacky workaround as discussed on the Ampache GitHub.

to work around the current ampache issue, you would need to adjust one DietPi file. As this is one of the core files and quite big, I would recommand to create a backup before. Changes on this file are needed only for this installation and would need to be rolled back afterwards
  1. lets do the backup

    Code: Select all

    cp -p /DietPi/dietpi/dietpi-software /DietPi/dietpi/dietpi-software_save
  2. on this file you would need to change 3 sections

    Code: Select all

    nano /DietPi/dietpi/dietpi-software
    1. search for the following line

      Code: Select all

      G_RUN_CMD unzip -o $file ${target:+"$target"}
      and change it into

      Code: Select all

      G_RUN_CMD unzip -o $file -d "./ampache-123"
    2. search for the following line

      Code: Select all

      Download_Install 'https://github.com/ampache/ampache/archive/master.tar.gz'
      and change it into

      Code: Select all

      no_check_url=1 Download_Install 'https://github.com/ampache/ampache/releases/download/4.1.1/ampache-4.1.1_all.zip'
    3. search for the following 2 lines

      Code: Select all

      mysql ampache < ampache.sql
      rm ampache.sql
      and change it into

      Code: Select all

      mysql ampache < ./ampache-123/ampache.sql
      rm ./ampache-123/ampache.sql
  3. if you already have Ampache installed, go to dietpi-software and uninstall it
  4. do a reboot
  5. and try to install Ampache again using dietpi-software
As dietpi-software is a huge file with more than 16.000 lines, I would recommend to use the search function within nano tool
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
edajai
Posts: 3
Joined: Sun Mar 15, 2020 9:42 pm

Re: Ampache doesn't install correctly - running DietPi v6.28.0 on RPi B (armv6l)

Post by edajai »

This worked well! Thanks a lot
User avatar
Joulinar
Posts: 2023
Joined: Sat Nov 16, 2019 12:49 am

Re: Ampache doesn't install correctly - running DietPi v6.28.0 on RPi B (armv6l)

Post by Joulinar »

pls don't forget to rollback the changes. Otherwise you could have issues on other software installation's.
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
Post Reply