Hardware: Serveur at my place YunoHost version: Debian Buster I have access to my server : Through SSH | through the webadmin Are you in a special context or did you perform some particular tweaking on your YunoHost instance ? : no
Hello Everyone,
I have problems with Nextcloud and I’m not sure what to do. Indeed, I tried to set up 2FA on Nextcloud just to try.
But I had no that much time so I decided to disabled this option and configured it later. When I tried to log-in with my Nextcloud Admin account, I had this error:
Two-step authentication has been enforced but is not configured on your account. Contact your administrator for assistance.
So I typed this command to remove the 2FA Authentification
Looks like you’re trying to reinstall your Nextcloud. However, the CAN_INSTALL file is missing from your configuration directory. Please create the CAN_INSTALL file in your configuration folder to continue
So I know this is not about Yunohost, but if anyone as an advice on this… I’m a bit lost and I don’t want to loose my Nextcloud
Hello
its not supposed to be a serious problem
i dont have nextcloud installed on my server so i don’t know where is yunohost nextcloud supposed to be
so you will need to deal with it by yourself and find it,
but generally its supposed to be here:
/var/www/nextcloud
next cloud by default do make a backup of its configs in several scenarios such as updates
its supposed to be some nextcloud_old or nextcloud.old
your issue seems like a defected config.php
if you find any nextcloud.old folder and you see a config.php make your current config.php backup in place you desire by smple copy it into another name and copy the old config to the current nextcloud folder
the same with CAN_INSTALL maybe you will find your old one,
after that all supposed to be normal, if not
create CAN_INSTALL file
and then create a new user and that should be fine.
Honestly: A big thanks you for your answer ! It helped me
So I looked for a “old Nextcloud” folder in my serveur but I couln’t find one.
I created a file CAN_INSTALL. Now, If I try to connect to the serveur I reach this page:
@pilou i don’t read french man, but as its looks like its looking for all the config.php configurations that used to be, while installation which is completely unknown
sql password, and so on, i think i am not sure what i see cause its all in French,
but once you set a CAN_INSTALL file
you should create a new user, otherwise you will not be able to login,
if i could read what is there i could maybe understand what is that,
but its look like according to you,
the installation details such as db password and other things which if you dont have the config.php at all so you will need to re-generate db password with commands for god knows what db is that i am not sure if its postgre or mysql even
find the config.php and open it where is it? get a screenshot of it
okay so basically its asking the whole database info,
first of all what do you see on /var/www/nextcloud/data?
any config.php?
dont try to insert any details in that form its not clear to me if that form is asking for existing info or will create a new configurations be careful!!!
maybe that form is creating a new db all your things will be erased
you should have all the details in the config?
database password:
do you see anything?
can you translate for me what its says on the form?:
its asking you to insert details?
before you try to do anything whatsoever don’t do anything!!!
you should make a backup through the admin panel
and also though a command
cd /
cd /var/www/
mkdir nextcloud.manual.backup
cp nextcloud nextcloud.manual.backup
so you have a backup through the admin panel thats ok,
so what i am thinking you can do in such situation is there is no choice you need to reinstall
your nextcloud, a new installation will produce a new salt + healthy config,
and then you probably can restore your data whether by yunohost restore or by command,
but don’t take the chance by just keeping the yunohost backup
copy them both to some directory so it will be safe, later you can delete that if you want,
after you did make sure you copied all the files yunohost backup + sql
remove nextcloud, install a new one, and try to restore with yunohost backup through the panel, if it will not go smooth, use the commands to rescan all files, it will arrange that automatically for each user, (in case there are users)
Thank you very much for your help. I had no time this week end I did a backup of sql + yunohost backup. I went to the admin panel to uninstall Nextcloud through “application”. But I have an error each time I try to click on Nextcloud. I can’t uninstall it.
So I guess I have to do it through commande line
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/moulinette/interfaces/api.py", line 494, in process
ret = self.actionsmap.process(arguments, timeout=30, route=_route)
File "/usr/lib/python3/dist-packages/moulinette/actionsmap.py", line 599, in process
return func(**arguments)
File "/usr/lib/moulinette/yunohost/user.py", line 1268, in user_permission_list
return user_permission_list(short, full, absolute_urls=True, apps=apps)
File "/usr/lib/moulinette/yunohost/permission.py", line 82, in user_permission_list
for app in apps
File "/usr/lib/moulinette/yunohost/permission.py", line 84, in <dictcomp>
and app_setting(app, "domain")
File "/usr/lib/moulinette/yunohost/app.py", line 1199, in app_setting
app_settings = _get_app_settings(app) or {}
File "/usr/lib/moulinette/yunohost/app.py", line 1773, in _get_app_settings
settings = {k: v for k, v in settings.items()}
AttributeError: 'NoneType' object has no attribute 'items'
no issue,
i could suggest what to do with command line, but i am not sure that will be the right thing,
i just don’t want you to get into bigger troubles,
i think it might cause the nextcloud installation being ruined from the first place while the config info gone, in that case i think @Aleks need to recommend what to do, if he doesn’t have any suggestion just comment and i will tell you how to do it with my methods
I was looking for some solutions and I found this typing this command
root@:/# df
Filesystem 1K-blocks Used Available Use% Mounted on
udev 3889908 0 3889908 0% /dev
tmpfs 780964 84036 696928 11% /run
/dev/sdb2 28660644 27966092 0 100% /
tmpfs 3904812 28 3904784 1% /dev/shm
tmpfs 5120 0 5120 0% /run/lock
tmpfs 3904812 0 3904812 0% /sys/fs/cgroup
/dev/sdb1 523248 3480 519768 1% /boot/efi
/dev/sdc1 960310988 152216700 759239864 17% /media/stockage
/dev/sda1 960302096 169959596 741488076 19% /home
tmpfs 780960 0 780960 0% /run/user/1007
root@premierdecordee:/# lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
sda 8:0 0 931.5G 0 disk
└─sda1 8:1 0 931.5G 0 part /home
sdb 8:16 0 223.6G 0 disk
├─sdb1 8:17 0 512M 0 part /boot/efi
├─sdb2 8:18 0 28G 0 part /
├─sdb3 8:19 0 977M 0 part [SWAP]
└─sdb4 8:20 0 194.2G 0 part
sdc 8:32 0 931.5G 0 disk
└─sdc1 8:33 0 931.5G 0 part /media/stockage
As you can see my partition sdb2 is full. But I don’t know why because it should only contain nextcloud, I guess. I’m wondering if I did a backup on the wrong disk. So that would explain why is it full no ?
i have no idea you should check what that partition include, what folders, files, just navigate to it, its just about 28gb, your partitioning looks little weird, your system drive is much smaller than the other drive of 256gb hard drive
sdb2 = 28g
sdb4 = 194g
your system drive should be much bigger than that if you’re asking me,
i dont know if you have a desktop environment installed on that system, but if not so the easiest way for you to check things will be with midnight commander
just install mc
sudo apt-get install mc
So maybe if I delete the sdb4 partition, I will have more space to let to the sdb2 partition.
Welcome to fdisk (util-linux 2.33.1).
Changes will remain in memory only, until you decide to write them.
Be careful before using the write command.
The old ext4 signature will be removed by a write command.
Device does not contain a recognized partition table.
Created a new DOS disklabel with disk identifier 0x3fb21ad0.
But i’m affraid to loose something -_-'. I guess if I find a way to have space on this partition I will be able to uninstall Nextcloud and Re-install it
once you have a primary partition table before the sdb4 you will not be able to merge them that way, cause the swap is between
it requires a special technics which i don’t want to get into it, its consuming a lot of time and dangerous,
let me to understand better the structure of your server, cause the communication with you is very slow probably you’re trying to face and solve things by yourself instead of to ask,
you have a pc case as i understand?
with 3 hard drives
as what is it exactly only yunohost?
don’t try to do thing by yourself why you think i am here ask me everything you need it will be easier and faster, be careful on your data,