-
Notifications
You must be signed in to change notification settings - Fork 33
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
Fixed the readlink in init script #110
Conversation
Init script had a logic to read the target location of the symlink using 'readlink'. But the result was not the target of the link. Now fixed it with removing the switch '-f' for 'readlink' This is what seen with cirros 0.5.2 $ readlink -f /etc/dropbear /etc/dropbear $ readlink /etc/dropbear /var/run/dropbear
Can you add more detail about how to reproduce the issue? Also note that 0.5.2 has been superceded by 0.5.3 or even the 0.6.x train, do you also see the issue there? |
I'm confused. I just looked at 0.5.2 and /etc/dropbear is a regular directory, not a symlink at all.
|
I'm confused. I just looked at 0.5.2 and /etc/dropbear is a regular directory, not a symlink at all. Also, it seems that 'readlink' without -f on a non-link returns empty output, with -f it will give the actual path. see below.
|
I am seeing the same issue with cirros-0.5.3, but haven't tested it with 0.6.z @smoser I used the same cirros 0.5.2 and created VM out of it.
Here the problem is that /etc/dropbear links to /var/run/dropbear. But this directory /var/run/dropbear is not available. |
You are right... i dont know what I was doing. I'll look at this further. |
@smoser Hi. This issue is not yet addressed. What is the plan to fix this issue with cirros ? |
For the next release this will be fixed by #118, I don't think we will support older releases. |
Init script 'S50-dropbear' updated 'dropbear_key_dir' variable to read the target location of the symlink using 'readlink'.
But the result was not the target of the link. Now fixed it with removing the switch '-f' for 'readlink'
Because of this issue, host keys are not generated and as a result unable to SSH in to cirros VMs
This is what seen with cirros 0.5.2
$ readlink -f /etc/dropbear
/etc/dropbear
$ readlink /etc/dropbear
/var/run/dropbear