question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. ItĀ collects links to all the places you might be looking at while hunting down a tough bug.

And, if youā€™re still stuck at the end, weā€™re happy to hop on a call to see how we can help out.

Question: Docker on Windows archiving to an SMB path that doesn't support FSYNC

See original GitHub issue

Iā€™ve been fighting with this long enough to hope that someone with more ArchiveBox and/or Docker knowledge can spot something Iā€™m doing wrong. Iā€™m attempting to run ArchiveBox on Windows following the docker-compose directions, with my Volume on an SMB path (my NAS, not my server).

First I make the volume: docker volume create --driver local --opt type=cifs --opt device=//<ipaddress>/ArchiveBox --opt o=username=<username>,password=<pass> ArchiveBox

Then I run the first command in the directions: docker-compose run archivebox init --setup

And hit errors:

Creating network "archivebox3_default" with the default driver
Creating archivebox3_archivebox_run ... done
[i] [2021-04-24 19:07:10] ArchiveBox v0.6.2: archivebox init --setup
    > /data

Traceback (most recent call last):
  File "/usr/local/lib/python3.9/logging/config.py", line 564, in configure
    handler = self.configure_handler(handlers[name])
  File "/usr/local/lib/python3.9/logging/config.py", line 745, in configure_handler
    result = factory(**kwargs)
  File "/usr/local/lib/python3.9/logging/handlers.py", line 153, in __init__
    BaseRotatingHandler.__init__(self, filename, mode, encoding=encoding,
  File "/usr/local/lib/python3.9/logging/handlers.py", line 58, in __init__
    logging.FileHandler.__init__(self, filename, mode=mode,
  File "/usr/local/lib/python3.9/logging/__init__.py", line 1146, in __init__
    StreamHandler.__init__(self, self._open())
  File "/usr/local/lib/python3.9/logging/__init__.py", line 1175, in _open
    return open(self.baseFilename, self.mode, encoding=self.encoding,
PermissionError: [Errno 13] Permission denied: '/data/logs/errors.log'

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/usr/local/bin/archivebox", line 33, in <module>
    sys.exit(load_entry_point('archivebox', 'console_scripts', 'archivebox')())
  File "/app/archivebox/cli/__init__.py", line 140, in main
    run_subcommand(
  File "/app/archivebox/cli/__init__.py", line 74, in run_subcommand
    setup_django(in_memory_db=subcommand in fake_db, check_db=cmd_requires_db and not init_pending)
  File "/app/archivebox/config.py", line 1136, in setup_django
    django.setup()
  File "/usr/local/lib/python3.9/site-packages/django/__init__.py", line 19, in setup
    configure_logging(settings.LOGGING_CONFIG, settings.LOGGING)
  File "/usr/local/lib/python3.9/site-packages/django/utils/log.py", line 75, in configure_logging
    logging_config_func(logging_settings)
  File "/usr/local/lib/python3.9/logging/config.py", line 809, in dictConfig
    dictConfigClass(config).configure()
  File "/usr/local/lib/python3.9/logging/config.py", line 571, in configure
    raise ValueError('Unable to configure handler '
ValueError: Unable to configure handler 'logfile'
ERROR: 1

A folder named ā€œlogsā€ is created, but nothing else. Obviously seems to be a permissions issue of some sort, but I donā€™t know enough to figure out what it is. Any suggestions or alternative approaches?

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:8 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
aluhrs13commented, Apr 25, 2021

Alright Iā€™ve bit a partial bullet and opted to just run ArchiveBox on my Synology instead of trying to fight this more. Feel free to close this out, unless thereā€™s something here you want to investigate further, Iā€™m happy to continue trying troubleshooting steps.

1reaction
aluhrs13commented, Apr 24, 2021

No dice šŸ˜¢, hereā€™s the contents of my docker-compose.yml in case itā€™s something there.

version: '2.4'

volumes:
  vol:
    external: true
    name: ArchiveBox

services:
    archivebox:
        image: ${DOCKER_IMAGE:-archivebox/archivebox:latest}     
        command: server --quick-init 0.0.0.0:8000
        ports:
            - 3081:8000
        environment:
            - ALLOWED_HOSTS=*
            - MEDIA_MAX_SIZE=750m
            - SUBMIT_ARCHIVE_DOT_ORG=False
        volumes:
            - vol:/data:z
Read more comments on GitHub >

github_iconTop Results From Across the Web

Upgrading or Merging Archives Ā· ArchiveBox ... - GitHub
#894 Ā· Question: Docker on Windows archiving to an SMB path that doesn't support FSYNC #722 Ā· Support for network drives or filesystems...
Read more >
Data directory "/var/lib/postgresql/data/pgdata" has wrong ...
In my example, I have a drive F: and map a host directory on this drive ā€œf:/data/docker/postgresql/dataā€ to the postgres data directory /var/libĀ ......
Read more >
Mount SMB/CIFS share within a Docker container
So, I have two questions: Am I correct in understanding that Docker prevents any use of mount inside containers? Can anyone think of...
Read more >
MongoDB refuse to start, operation not permitted
I'm trying to mount /data/db from my Windows dev PC but everytime I try, Mongo crashes as it seems to not have the...
Read more >
Windows Subsystem for Linux: The lost potential | Hacker News
Perhaps worse than this being a problem is that Microsoft don't seem to ... Docker support is precisely the sort of feature that...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found