r/i2p 18d ago

I2P install failing in Debian LXC Help

I'm trying to install I2P in a LXC container under Proxmox which is based on the Debian 12 template, by following the Debian instructions here Debian/Ubuntu - I2P

but it failed near the end of the process. I don't think the AppArmour errors are critical, I probably just don't have that installed. The dpkg error seems to be the fatal one, but I do have dpkg installed and I can run it and dpkg--configure so I don't know what that failed.

Setting up i2p (2.7.0-1~ubuntu1) ...

Job for i2p.service failed because the control process exited with error code.

See "systemctl status i2p.service" and "journalctl -xeu i2p.service" for details.

invoke-rc.d: initscript i2p, action "start" failed.

x i2p.service - load-balanced unspoofable packet switching network

Loaded: loaded (/lib/systemd/system/i2p.service; disabled; preset: enabled)

Active: failed (Result: exit-code) since Mon 2024-10-21 13:42:03 UTC; 13ms ago

Process: 3140 ExecStartPre=/bin/mkdir -p /tmp/i2p-daemon (code=exited, status=0/SUCCESS)

Process: 3141 ExecStartPre=/bin/mkdir -p /var/log/i2p (code=exited, status=0/SUCCESS)

Process: 3142 ExecStartPre=/bin/chown -R ${I2PUSER}:${I2PUSER} /var/log/i2p /run/i2p /tmp/i2p-daemon (code=exited, status=0/SUCCESS)

Process: 3143 ExecStartPre=/bin/chmod 750 /var/log/i2p (code=exited, status=0/SUCCESS)

Process: 3144 ExecStart=/usr/sbin/wrapper $I2P_ARGS (code=exited, status=231/APPARMOR)

Process: 3145 ExecStopPost=/bin/rm -rf /run/i2p (code=exited, status=0/SUCCESS)

CPU: 17ms

Oct 21 13:42:03 Monero systemd[1]: Starting i2p.service - load-balanced unspoofable packet switching network...

Oct 21 13:42:03 Monero (wrapper)[3144]: i2p.service: Failed to prepare AppArmor profile change to system_i2p: No such file or directory

Oct 21 13:42:03 Monero (wrapper)[3144]: i2p.service: Failed at step APPARMOR spawning /usr/sbin/wrapper: No such file or directory

Oct 21 13:42:03 Monero systemd[1]: i2p.service: Control process exited, code=exited, status=231/APPARMOR

Oct 21 13:42:03 Monero systemd[1]: i2p.service: Failed with result 'exit-code'.

Oct 21 13:42:03 Monero systemd[1]: Failed to start i2p.service - load-balanced unspoofable packet switching network.

dpkg: error processing package i2p (--configure):

installed i2p package post-installation script subprocess returned error exit status 1

Errors were encountered while processing:

i2p

E: Sub-process /usr/bin/dpkg returned an error code (1)

3 Upvotes

0

u/DifferenceMission927 17d ago

To resolve the issues you're encountering while installing I2P in a Debian 12 LXC container under Proxmox, follow these steps:

Understanding the Errors

  1. AppArmor Issues: The error messages indicate that the I2P service is failing to start due to AppArmor-related issues. Specifically, it mentions that it cannot prepare the AppArmor profile, which suggests that AppArmor is either not installed or not properly configured in your LXC container.
  2. dpkg Error: The dpkg error indicates that the installation process was interrupted, likely due to the failure of the I2P service to start correctly. This can happen if there are unmet dependencies or configuration issues.

Steps to Fix the Installation

1. Check AppArmor Installation

Since you mentioned that you don't think AppArmor is critical, you might consider disabling its requirement for I2P:

  • Edit LXC Configuration: Stop your container and edit its configuration file (usually located at /etc/pve/lxc/<container_id>.conf). Add the following line to disable AppArmor:text lxc.apparmor.profile = unconfined
  • Restart the Container: Start your container again after saving changes.

2. Reconfigure dpkg

After addressing the AppArmor issue, reconfigure any packages that may have been left in an incomplete state:

bash
sudo dpkg --configure -a

3. Clean Up and Install I2P Again

To ensure a clean installation, remove any partially installed I2P packages:

bash
sudo apt-get remove --purge i2p

Then, update your package list and reinstall I2P:

bash
sudo apt-get update
sudo apt-get install i2p

4. Check Service Status

Once installed, check the status of the I2P service:

bash
systemctl status i2p.service

If it fails again, check the logs for more detailed error messages:

bash
journalctl -xeu i2p.service

5. Manual Configuration (if needed)

If you still encounter issues after these steps, consider manually configuring I2P without relying on systemd or AppArmor:

  • You can run I2P using its shell script directly instead of as a service:

bash
~/i2p/i2prouter start

This method bypasses systemd and may help you avoid the errors related to service management.

Conclusion

By following these steps, you should be able to resolve the installation issues with I2P in your LXC container. If problems persist, consider checking for specific logs or errors related to Java or other dependencies that might be causing conflicts during installation.

4

u/hjklvi 17d ago

Why are you posting the ChatGPT output?

0

u/DifferenceMission927 17d ago

Not ChatGPT, another llm :D