Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Backup script fails during update on Windows when paths exceed 260 char limit #1087

Open
Vonken opened this issue Mar 12, 2020 · 3 comments
Open

Comments

@Vonken
Copy link

Vonken commented Mar 12, 2020

Can't update to new version. Running OpenHab 2.4.0 on Windows. If I run from PowerShell the window is closed at the last point and I was unable to catch the error so I tested from CMD and got this error:
image

@wborn
Copy link
Member

wborn commented Apr 26, 2020

That path seems to exceed the max path length of Windows that is 260 chars according to these docs.

There are 264 chars in:

C:\Users\Familjen i Lerkil\AppData\Local\Temp\openhab\backup-2.4.0\runtime\system\org\eclipse\smarthome\automation\org.eclipse.smarthome.automation.module.script.defaultscope\0.10.0.oh240\org.eclipse.smarthome.automation.module.script.defaultscope-0.10.0.oh240.jar

Perhaps enabling longer paths can be used as a workaround?

@wborn wborn changed the title Update issue from 2.4.0 to 2.5.2 - Could not backup existing distribution Backup script fails during update on Windows when paths exceed 260 char limit Apr 26, 2020
@Vonken
Copy link
Author

Vonken commented Apr 27, 2020

Thanks for the answer! Did a fresh install and copied all files and settings but this will propebly help me in the next upgrade or someone else.

@J-N-K
Copy link
Member

J-N-K commented Dec 18, 2021

This also happens if bundles installed from the marketplace (especially kar-files) are used. The reason is that they easily exceed 255 characters as they are unpacked to <userdata>/tmp/kar/<filename>. Since tmp, cache and backup are removed after copying anyway, this is a bit annoying.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants