# Mount cifs works on RL 8 but not on RL9?

**URL:** https://forums.rockylinux.org/t/mount-cifs-works-on-rl-8-but-not-on-rl9/14275
**Category:** Rocky Linux Help & Support
**Tags:** rocky-linux-9, rocky-linux-8
**Created:** [May 27, 2024, 12:39pm UTC](https://forums.rockylinux.org/t/mount-cifs-works-on-rl-8-but-not-on-rl9/14275 "2024-05-27T12:39:33Z")
**Posts on this page:** 13
**Page:** 1

<div class="post-metadata">

### Author: ![astral](https://sea2.discourse-cdn.com/flex020/user_avatar/forums.rockylinux.org/astral/32/4314_2.png) [@astral](https://forums.rockylinux.org/u/astral)
#### Post date: [May 27, 2024, 12:39pm UTC](https://forums.rockylinux.org/t/mount-cifs-works-on-rl-8-but-not-on-rl9/14275/1 "2024-05-27T12:39:33Z")

</div>

Hello,

I have 2 Rockylinux server, one is 8.9 the other one is 9.4.  
Both use the same “mount” command to connect to an old IBM as400, to grab a csv and publish some data on a webserver.  
My problem is:  
everything worked for a year, now the command on RL 9 is not working anymore but RL8 works fine.

Command is:

`mount -t cifs //ipaddr/path/PATH/PATH/ /mnt/mountfolder -o vers=1.0,username=xxx,password=xxx,nofail,ro,noserverino`

But when I launch it from the consolle this is the message:

```auto
mount error(22): Invalid argument
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs) and kernel log messages (dmesg)

```

This is what I see from dmesg

```auto

[119134.706595] CIFS: VFS: Use of the less secure dialect vers=1.0 is not recommended unless required for access to very old servers
[119134.706601] CIFS: Attempting to mount //ipaddr/path/PATH/PATH/
[119134.710001] CIFS: VFS: cifs_mount failed w/return code = -22

```

Can’t find other details.  
I know vers=1.0 is not ideal but it’s necessary. Maybe RL9 doesn’t allow mounting cifs with vers 1.0 anymore?

Any help is apreciated, not a super-expert here.  
Thanks

---

<div class="post-metadata">

### Author: ![iwalker](https://sea2.discourse-cdn.com/flex020/user_avatar/forums.rockylinux.org/iwalker/32/2599_2.png) [@iwalker](https://forums.rockylinux.org/u/iwalker)
#### Post date: [May 27, 2024, 1:23pm UTC](https://forums.rockylinux.org/t/mount-cifs-works-on-rl-8-but-not-on-rl9/14275/2 "2024-05-27T13:23:22Z")

</div>

> [@astral](#):
>
> mount -t cifs //ipaddr/path/PATH/PATH/ /mnt/mountfolder -o vers=1.0,username=xxx,password=xxx,nofail,ro,noserverino

Can you try removing the parameters from the end of the line. Eg, nofail noserverino in case one of these are the fault.

Ideally, providing `mount -vvv` would give a lot more error output and would help in diagnosing which flag is the problem. I doubt very much the vers=1.0 is the issue here.

---

<div class="post-metadata">

### Author: ![astral](https://sea2.discourse-cdn.com/flex020/user_avatar/forums.rockylinux.org/astral/32/4314_2.png) [@astral](https://forums.rockylinux.org/u/astral)
#### Post date: [May 27, 2024, 1:41pm UTC](https://forums.rockylinux.org/t/mount-cifs-works-on-rl-8-but-not-on-rl9/14275/3 "2024-05-27T13:41:13Z")

</div>

Hello,

- if i remove vers=1.0

```auto
mount error: Server abruptly closed the connection.
This can happen if the server does not support the SMB version you are trying to use.
The default SMB version recently changed from SMB1 to SMB2.1 and above. Try mounting with vers=1.0.
mount error(112): Host is down
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs) and kernel log messages (dmesg)

```

- if i remove username, command try to connect with user root (wrong)
- if i remove password, the server ask me for it and when I manually insert it this is the strange message:

```auto
mount.cifs kernel mount options: ip=10.10.x.x,unc=\\10.10.x.x\FIRST_ FOLDER_ OF_THE_PATH,vers=1.0,user=as400,prefixpath=SECOND_ FOLDER_OF_THE_PATH/THIRD_ FOLDER_OF_THE_PATH/,pass= ********
mount error(22): Invalid argument

```

- if i remove “nofail, ro, noserverino” message is always

```auto
mount error(22): Invalid argument
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs) and kernel log messages (dmesg)

```

Seems that problem is caused by the password argument?

---

<div class="post-metadata">

### Author: ![hortimech](https://avatars.discourse-cdn.com/v4/letter/h/b9bd4f/32.png) [@hortimech](https://forums.rockylinux.org/u/hortimech)
#### Post date: [May 27, 2024, 3:21pm UTC](https://forums.rockylinux.org/t/mount-cifs-works-on-rl-8-but-not-on-rl9/14275/4 "2024-05-27T15:21:19Z")

</div>

Where you are trying to mount from looks suspect ‘//ipaddr/path/PATH/PATH/’ , it is usually ‘//server/share’ not a UNC.

---

<div class="post-metadata">

### Author: ![astral](https://sea2.discourse-cdn.com/flex020/user_avatar/forums.rockylinux.org/astral/32/4314_2.png) [@astral](https://forums.rockylinux.org/u/astral)
#### Post date: [May 28, 2024, 7:33am UTC](https://forums.rockylinux.org/t/mount-cifs-works-on-rl-8-but-not-on-rl9/14275/5 "2024-05-28T07:33:59Z")

</div>

Believe me: on RL8 the mount command is working perfectly fine with the exact same settings and even on RL9 it worked for a year. Don’t know if an update broke something, couple of weeks ago.  
Anyway, if this is the problem, how could I mount (and download) a specific file located in a subfolder “//ipaddr/path/PATH/PATH/” ?

Thanks

---

<div class="post-metadata">

### Author: ![iwalker](https://sea2.discourse-cdn.com/flex020/user_avatar/forums.rockylinux.org/iwalker/32/2599_2.png) [@iwalker](https://forums.rockylinux.org/u/iwalker)
#### Post date: [May 28, 2024, 7:46am UTC](https://forums.rockylinux.org/t/mount-cifs-works-on-rl-8-but-not-on-rl9/14275/6 "2024-05-28T07:46:17Z")

</div>

Possibly something in 9.4 kernel assuming you upgraded to 9.4 from say 9.3. You could boot the previous kernel from the grub menu and see if it works again.

---

<div class="post-metadata">

### Author: ![astral](https://sea2.discourse-cdn.com/flex020/user_avatar/forums.rockylinux.org/astral/32/4314_2.png) [@astral](https://forums.rockylinux.org/u/astral)
#### Post date: [May 28, 2024, 8:35am UTC](https://forums.rockylinux.org/t/mount-cifs-works-on-rl-8-but-not-on-rl9/14275/7 "2024-05-28T08:35:15Z")

</div>

YES!

Booted “old” kernel 5.14.0-362.24.1.el9\_3.0.1.x86\_64 and problem is solved.  
Retried with latest 5.14.0-427.16.1.el9\_4.x86\_64 and problem appears again.

Another confirm is that our last working file transfer was on 11 May, on 12 of May RL9.4 was automatically updated.

So, what can we do now? If I reboot on the old kernel it will update by itself or move to 9.4 at the first reboot? By the way I don’t like to keep the server not updated, any idea how to solve this on 9.4 ? Anything to check?

Thanks.

---

<div class="post-metadata">

### Author: ![iwalker](https://sea2.discourse-cdn.com/flex020/user_avatar/forums.rockylinux.org/iwalker/32/2599_2.png) [@iwalker](https://forums.rockylinux.org/u/iwalker)
#### Post date: [May 28, 2024, 8:56am UTC](https://forums.rockylinux.org/t/mount-cifs-works-on-rl-8-but-not-on-rl9/14275/8 "2024-05-28T08:56:25Z")

</div>

Red Hat made a load of changes in 9.4 kernel, so without being a part of the infrastructure team, I’m unable to say what that was. @label might be able to tell what was changed on that.

Alternatively, elrepo can be used, and you can use either kernel-lt or kernel-ml, which will be 6.x kernels rather than 5.14.x kernels that are in Rocky by default. That may be worth trying and using instead. There is also a possibility that Rocky SIG Kernels could also be used which could have the updated 5.14.x kernel, but with the options enabled that you are looking for.

---

<div class="post-metadata">

### Author: ![astral](https://sea2.discourse-cdn.com/flex020/user_avatar/forums.rockylinux.org/astral/32/4314_2.png) [@astral](https://forums.rockylinux.org/u/astral)
#### Post date: [May 28, 2024, 10:17am UTC](https://forums.rockylinux.org/t/mount-cifs-works-on-rl-8-but-not-on-rl9/14275/9 "2024-05-28T10:17:54Z")

</div>

Tried installing elrepo LT 6.1.92-1.el9.elrepo.x86\_64 , problem is fixed. (had to disable secure boot, otherwise system won’t boot).  
Is this kernel a safe solution for a production environment?

To me problem is fixed, however any other details on this topic could be helpful for someone else.

Many thanks!

---

<div class="post-metadata">

### Author: ![jlehtone](https://avatars.discourse-cdn.com/v4/letter/j/e9a140/32.png) [@jlehtone](https://forums.rockylinux.org/u/jlehtone)
#### Post date: [May 28, 2024, 10:27am UTC](https://forums.rockylinux.org/t/mount-cifs-works-on-rl-8-but-not-on-rl9/14275/10 "2024-05-28T10:27:31Z")

</div>

> [@astral](#):
>
> problem is solved

I would not say “solved”. “Located”, perhaps. We now know that it is something where 5.14.0-427.el9 differs from 5.14.0-362.el9.

One could browse the changelog:  
`rpm -q --changelog kernel-5.14.0-427.16.1.el9_4 | less`  
or more to the point:

```auto
rpm -q --changelog kernel-5.14.0-427.16.1.el9_4 | grep -iE "^\*|smb|cifs" | less

```

but whether any of it is telling is an another story.

* * *

> [@astral](#):
>
> So, what can we do now? If I reboot on the old kernel it will update by itself or move to 9.4 at the first reboot?

There are two options for such boot issue:

1. Exclude kernel packages from updates
2. Edit `/etc/sysconfig/kernel` to prevent update from changing GRUB default. Then set the 5.14.0-362.24.1 as the default entry. This is probably the “cleaner” way

* * *

> [@astral](#):
>
> Tried installing elrepo LT 6.1.92-1.el9.elrepo.x86\_64 , problem is fixed. (had to disable secure boot, otherwise system won’t boot).  
> Is this kernel a safe solution for a production environment?

ELRepo builds the kernel packages from upstream sources. Kernel developers do patch the LT sources and ELRepo is a reputable repo.

---

<div class="post-metadata">

### Author: ![astral](https://sea2.discourse-cdn.com/flex020/user_avatar/forums.rockylinux.org/astral/32/4314_2.png) [@astral](https://forums.rockylinux.org/u/astral)
#### Post date: [May 28, 2024, 10:51am UTC](https://forums.rockylinux.org/t/mount-cifs-works-on-rl-8-but-not-on-rl9/14275/11 "2024-05-28T10:51:35Z")

</div>

You’re right, “located” is more correct than “solved”, sorry but English is not my native language.  
I just tried to open changelog as you suggest but it’s too much for my basic linux skills to find anything relevant 🙂  
About elrepo kernel 6 OK, good, I will keep it.

Thanks

---

<div class="post-metadata">

### Author: ![gerry666uk](https://avatars.discourse-cdn.com/v4/letter/g/dbc845/32.png) [@gerry666uk](https://forums.rockylinux.org/u/gerry666uk)
#### Post date: [May 28, 2024, 7:36pm UTC](https://forums.rockylinux.org/t/mount-cifs-works-on-rl-8-but-not-on-rl9/14275/12 "2024-05-28T19:36:25Z")

</div>

There was a Kconfig setting  
`config CIFS_ALLOW_INSECURE_LEGACY`  
BUT

```auto
old : linux-5.14.0-362.24.1.el9_3/fs/cifs/
new : linux-5.14.0-427.16.1.el9_4/fs/smb/

```

they changed the kernel source, cifs has gone, and now it’s called smb, and the Kconfig is different

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/flex020/uploads/rockylinux/original/1X/91b7219eec10e30013422e4df76c1d898711a5d5.svg) [@system](https://forums.rockylinux.org/u/system)
#### Post date: [July 27, 2024, 7:37pm UTC](https://forums.rockylinux.org/t/mount-cifs-works-on-rl-8-but-not-on-rl9/14275/13 "2024-07-27T19:37:10Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
