# Command line disable Two Factor Authentication

**URL:** <https://meta.discourse.org/t/command-line-disable-two-factor-authentication/121480>\
**Category:** Product Support\
**Created:** [June 27, 2019, 9:54am UTC](https://meta.discourse.org/t/command-line-disable-two-factor-authentication/121480 "2019-06-27T09:54:06Z")\
**Posts on this page:** 1\
**Showing post:** 11

<div class="post-metadata">

**Author:** ![Dat\_Nguyen](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/dat_nguyen/32/160485_2.png) [@Dat\_Nguyen](https://meta.discourse.org/u/Dat_Nguyen)\
**Post date:** [March 25, 2020, 1:51am UTC](https://meta.discourse.org/t/command-line-disable-two-factor-authentication/121480/11 "2020-03-25T01:51:01Z")

</div>

> [@simon](#):
>
> Bạn sẽ thấy một dấu nhắc kết thúc bằng một cái gì đó tương tự như thế này: `/var/www/discourse#`
> 
> Tại dấu nhắc đó, nhập `rails c` và nhấn phím enter của bạn. Bây giờ bạn sẽ thấy một dấu nhắc trông giống như thế này : `pry(main)> ` . Đây là bảng điều khiển đường ray.
> 
> Để vô hiệu hóa xác thực yếu tố thứ hai bắt buộc, nhập `SiteSetting.enforce_second_factor="no"` và nhấn phím enter của bạn.

Thanks, the instructions are very clear and detailed. I did the following, but still required 2-factor authentication when logging in. Do not know where is wrong?

```
root@hoi-dap:/var/discourse# ./launcher enter app
root@hoi-dap-app:/var/www/discourse# rails c
[1] pry(main)> SiteSetting.enforce_second_factor='no'
=> "no"
[2] pry(main)> exit
root@hoi-dap-app:/var/www/discourse# exit
logout

```

---

_[View the full topic](https://meta.discourse.org/t/command-line-disable-two-factor-authentication/121480)._
