Posts by DaveOB

    A few clamAV questions.

    After installing the plugin, there's 3 sections under Services > Antivirus


    Settings

    On Access Scans

    Scheduled Scans


    Once Settings is enabled, will that check every new file that gets moved to the NAS ?

    or do I also need to add an 'on access scan' for every one of the Shared Folders on the NAS ?

    Schedules Scans also appears to be on a 'per folder' basis, so should add a Scheduled Scan for each of the shared folders, say once a week ?

    WiFi and LAN not working the same. What am I missing ?


    OMV7 on Pi 4b.
    OS on SD card

    Data on SSD

    LAN connection to Fiber.

    Normal setup is Cron executing php script on SSD.

    Script executes 100% and has been running perfectly for years.


    Lately had some power / fiber connection issues, and want to setup alternate method.


    My Phone has Mobile Data and Hotspot.

    Added the Hotspot details to OMV7 as a WiFi Interface.

    If I unplug the LAN cable from the Pi and turn on the phone Hotspot, the Pi is connected to the phones Hotspot. I can connect / browse from phone to Pi without issues.


    When the cron tries to execute the script ( or if I login to OMV via the phone browser and Run the cron manually ), I am getting an error :


    500 - Internal Server Error

    Failed to execute command 'export PATH=/bin:/sbin:/usr/bin:/usr/sbin:/

    usr/local/bin:/usr/local/sbin; export LC ALL-C.UTF-8; export LANGUAGE=;

    export SHELL=/bin/sh; sudo --shell -- non-interactive --user='root'--

    /var/lib/openmediavault/cron.d/use rdefined-5ffefff6-ed53-49e4-

    a638-15a770cb2c84 2>&1' with exit code '1': Could not open input

    file: /var/www/html/xxxgo.php



    The cron also sends a results e-mail to my default mail address saying :

    Code
    Could not open input file: /var/xxx/xxx/xxx/xxgo.php


    If I disable the Hotspot and plug the LAN cable back in to the Pi, it again runs exactly as expected.

    I know I'll get told this isn't the right way, but got tired of wasting time trying to solve it.
    I simply added a scheduled task to restart postfix once an hour.
    Not had an issue with it since. Been about 6 or 7 weeks like this.

    Hi

    I have a Pi4 32bit OS with OMV6 on SD with data on SSD.

    Changing to OMV7 on 64bit


    Used a spare Pi400 to setup OMV7, using new SD card and cloned SSD.

    Got all my setup correct and functioning 100%


    Now want to move the 64bit OS OMV7 SD card from the test Pi400, to my main Pi4


    Pi4 is headless.


    SD in to Pi4, and no IP address appears in the router ARP table.

    Downloaded Angry IP and scanned full IP range and nothing listed.


    Moved the SD card BACK to the Pi400, and shows up perfectly.


    Advice please.

    ryecoaaron - I see this appears to be a common problem you working on.


    Just an observation, in case it hints to the problem/ solution :


    I had my email listed as the sender and the recipient. As soon as I changed the Notifications > Settings > Recipient to my gmail account, all the mails started flowing again.

    Not sure if it's because the sender and recipient was the same, or if the sender and recipient are now completely different services ?


    2c

    - /path/to/custom/php.ini:/usr/local/etc/php/php.ini:ro

    You are awesome as always !


    I put the php.ini file in the same folder as the php-apache.yml file, and used the Absolute Path from the Shared Folders list to add the Volume to the Compose File.


    Tested by making a small change to the php.ini file, Stopped and UP'd the Container, and changes reflected correctly.


    new Compose File :



    Code
    services:
    php-apache:
    image: php:8.2-apache
    container_name: php-webserver
    working_dir: /var/www/html
    volumes:
    - /srv/dev-disk-by-uuid-ab32bc62-5c9c-467c-8348-xxxxxxxx/www/www:/var/www/html
    - /srv/dev-disk-by-uuid-ab32bc62-5c9c-467c-8348-xxxxxxxx/DocCompose/php-apache/php.ini:/usr/local/etc/php/php.ini:ro
    ports:
    - "80:80"

    OMV7 on a Pi4.

    Replacing an OMV6 setup.

    Notification email settings identical between the 2 systems.


    Test mail not coming thru. ( yes, checked spam folders ).

    Notifications from Scheduled Tasks also not sending.


    When System Reboot and system starts up, all emails suddenly come thru ( with their correct time stamp ).


    In fact, I'm now getting DUPLICATE mails that came thru at the time of the last reboot.


    Am I missing a setting ?

    Select the php-apache example.

    OMG !!!!! You make this so simple ! It works and the kettle hasn't even boiled yet !!


    Thank You


    html pages display, and the phpinfo.php displays.


    I assume there's a config or settings page or file somewhere for php ?

    Would that exist only in the docker Container and need to be recreated if the Container is recreated ?


    edit ..


    Been doing some googling, and it appears that php is installed in the new container with the default php.ini file.

    To have a php.ini file that exists outside the Image / Container, a php.ini file could be placed in the Docker Compose folder ( same location as the php-apache.yml file, and have it added to the Image when the image is created in a DockerFile ?

    Does this sound like a viable option ?



    side note : It was previously mentioned to "use a sharedfolder that points to /srv/dev-disk-by-uuid-ab32bc62-5c9c-467c-8348-d53ccd5627e9/www for the data directory on the settings tab of the plugin"
    I was unsure about this, as it would ( I think ) redirect all docker data usage for all docker containers to that 'www' shared folder. So after seeing the great php-apache option working, I removed the container, reset the data directory on the settings tab, and restarted Docket.
    Everything still works, so it appears that the data directory ( listed in the settings tag ) does not have any effect on this Container.

    side note : I have the OMV dashboard set to port 90, so port 80 is free for the web server.


    I gave up on the nginx and php idea, and instead found a Compose file for Apache php :


    Code
    services:
    httpd:
    image: httpd:2.4
    volumes:
    - /srv/dev-disk-by-uuid-ab32bc62-5c9c-467c-8348-d53ccd5627e9/www/www:/usr/local/apache2/htdocs/
    ports:
    - 80:80
    restart: unless-stopped


    It runs without generating any errors, and I can see the html pages from a browser. It's not running the php yet - it's simply listing the content of the php code in the browser, like a text editor view.


    I think it's something to do with the apache config, but I can't find where to change that. The path that the apache page mentions, does not appear to exist on the Pi.

    I am assuming it's hidden somewhere in the docker container.


    tomorrow's another day. Thanks for trying to help. Very much appreciated.

    Post the stack.


    in the Compose File, I changed the Volume to the ID ( I think the 'by label' was carried over from a previous upgrade from omv5 to omv6


    Thanks Aaron


    I'm more confused and understand less after wasting 10 hours on this problem today.


    I simply can't grasp all this. Probably too old. I feel like I shouldn't have bought a car if I can't change an oil seal on a gearbox !


    Going to revert back to the 32bit Pi OS with omv6 and probably stay with that until it breaks :)

    It did? Using the compose plugin?

    maybe I misunderstand how it worked. on OMV6 there was a Portainer Stack that created the Container, and I have php scripts in a shared folder on my SSD that I can run. So I am guessing that the php was installed in the container somehow.


    php-apache example to the compose plugin

    where would I find this ?