tencent cloud

Feedback

Infinite Loop Call in /etc/profile

Last updated: 2024-01-06 17:32:18

    Issue Description

    When you use SSH to log in to a Linux instance, the SSH command gets stuck after outputting the "Last login: " information.

    Common Causes

    This problem is probably because the /etc/profile file was modified, so /etc/profile was called in /etc/profile, resulting in an infinite loop call and inability to log in successfully.

    Solution

    Check and repair the /etc/profile file as instructed in Steps.

    Steps

    2. Run the following command to view the /etc/profile file.
    vim /etc/profile
    3. Check whether the /etc/profile file contains commands related to /etc/profile.
    If yes, go to the next step.
    If no, submit a ticket for assistance.
    4. Press i to enter the edit mode and add # before the relevant commands in /etc/profile to comment them.
    5. Press Esc to exit the edit mode, and enter :wq to save the modification.
    6. Log in to the Linux instance again by using SSH.
    Contact Us

    Contact our sales team or business advisors to help your business.

    Technical Support

    Open a ticket if you're looking for further assistance. Our Ticket is 7x24 avaliable.

    7x24 Phone Support