ssh questions

azlobo73 azlobo73 at gmail.com
Thu Sep 1 23:12:50 MST 2011


Good guess.  :2 is line 2, :3 is line 3

The answer to the second might also help clear up the first (if you are
connecting to the same machine  using different names, or if you used to
connect to a host/ip using one, but upgraded/changed the system (including
host keys) then connect using another):

.bashrc is sourced during non-interactive shell actions (scripts, crontabs,
etc), while .bash_profile or .profile is source during interactive shells
(logins, etc).

If you set/use aliases or functions (can work like alias but can take args -
$1 $2 $@ etc - in places middle of commands, not just append blindly at end
of alias cmd line) to short-hand ssh host connections, you might check for
'triggerfish' or '192.168.2.124' and standardize on one.



Ben

On Mon, Aug 29, 2011 at 7:23 AM, kitepilot at kitepilot.com <
kitepilot at kitepilot.com> wrote:

> You can also set these options in /etc/ssh/sshd_config or ~/.ssh/config
> ET
>
> kitepilot at kitepilot.com writes:
>
>> ssh -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no user at box
>> YMMV...
>> ET
>>
>> Dazed_75 writes:
>>
>>> 1) I have a number of machines where I often ssh from one to another.  I
>>> just did that with a regular pair and got:
>>> Warning: the RSA host key for 'triggerfish' differs from the key for the
>>> IP
>>>
>>>> address '192.168.2.124'
>>>> Offending key for IP in /home/larry/.ssh/known_hosts:2
>>>> Matching host key in /home/larry/.ssh/known_hosts:3
>>>> Are you sure you want to continue connecting (yes/no)? yes
>>>> Linux triggerfish 2.6.32-33-generic #72-Ubuntu SMP Fri Jul 29 21:07:13
>>>> UTC
>>>> 2011 x86_64 GNU/Linux
>>>> Ubuntu 10.04.3 LTS
>>>> I GUESS but do not KNOW that the known_hosts[2] and [3] refer to the 2nd
>>>>
>>> and 3rd or 3rd and 4th entries out of the 12 that exist.  I do NOT want
>>> to
>>> be editing those all the time so does anyone know a way to avoid that?
>>> 2) When I ssh into a machine, it is not clear what if any aliases from
>>> .bashrc or .bash_profile are in play (from the originationg machine/user
>>> or
>>> the target?  It often seems like neither.
>>> --
>>> Dazed_75 a.k.a. Larry
>>> The spirit of resistance to government is so valuable on certain
>>> occasions,
>>> that I wish it always to be kept alive.
>>>  - Thomas Jefferson
>>>
>> ------------------------------**---------------------
>> PLUG-discuss mailing list - PLUG-discuss at lists.plug.**phoenix.az.us<PLUG-discuss at lists.plug.phoenix.az.us>
>> To subscribe, unsubscribe, or to change your mail settings:
>> http://lists.PLUG.phoenix.az.**us/mailman/listinfo/plug-**discuss<http://lists.PLUG.phoenix.az.us/mailman/listinfo/plug-discuss>
>>
> ------------------------------**---------------------
> PLUG-discuss mailing list - PLUG-discuss at lists.plug.**phoenix.az.us<PLUG-discuss at lists.plug.phoenix.az.us>
> To subscribe, unsubscribe, or to change your mail settings:
> http://lists.PLUG.phoenix.az.**us/mailman/listinfo/plug-**discuss<http://lists.PLUG.phoenix.az.us/mailman/listinfo/plug-discuss>
>



-- 
---
Ben

python -c "exec(\"import math\\nprint ''.join(map(lambda x: chr(x), (
(ord('a')-(3*5)), int(math.sqrt(math.pi*76)*5+2), int(math.ceil(math.e)*28),
int(math.floor(math.e)*35), long(abs(4%3*35+3)*2))))\")"**
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.PLUG.phoenix.az.us/pipermail/plug-discuss/attachments/20110901/bb424ebf/attachment.html>


More information about the PLUG-discuss mailing list