Solved

How do I delete a file with special characters in Linux that has been created by SAMBA?

Posted on 2009-04-09
1
330 Views
Last Modified: 2013-12-16
I use Samba for my fileserver. Files created from Windows with spaces and special characters create problems. From Windows I can delete or rename the files, but not from the command prompt on the server. I need to be able to delete or rename the files from Linux, not just from Windows.

Server: RHEL 5

"Filsystem med kun lesetilgang" is Norwegian and means "Filesystem with only read access".
[root@mymachine div]# ll
totalt 128
-rwxr-x--- 1 hans felles 41483 jun 17  2007 Bilde 016.jpg
-rwxr-x--- 1 hans felles 33008 jun 17  2007 div 2 ?r 001.jpg
-rwxr-x--- 1 hans felles 33008 jun 17  2007 div 2 ?r 001.jpg
[root@mymachine div]# 
 
 
[root@mymachine div]# rm -f *
rm: cannot remove «Bilde 016.jpg»: Filsystem med kun lesetilgang
rm: cannot remove «div 2 \345r 001.jpg»: Filsystem med kun lesetilgang
rm: cannot remove «div 2 \206r 001.jpg»: Filsystem med kun lesetilgang
[root@mymachine div]#

Open in new window

0
Comment
Question by:ictb
1 Comment
 

Accepted Solution

by:
chiragypatil earned 125 total points
ID: 24105401
The error message says
rm: cannot remove «Bilde 016.jpg»:
which means the file name is being read as a whole. The problem here ,i think, is read access.
Try to unmount the file system and then mount the file system again with read and write permissions for the root user.
0

Featured Post

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Weird Samba Connectivity Issue... 7 40
Best way to virtualise a remote Linux server 2 66
add some character at the end of line in vi 7 79
maybe no no httpd.conf 6 47
In my business, I use the LTS (Long Term Support) versions of Linux. My workstations do real work, and so I rarely have the patience to deal with silly problems caused by an upgraded kernel that had experimental software on it to begin with from a r…
The purpose of this article is to demonstrate how we can upgrade Python from version 2.7.6 to Python 2.7.10 on the Linux Mint operating system. I am using an Oracle Virtual Box where I have installed Linux Mint operating system version 17.2. Once yo…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question