LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 01-15-2019, 11:33 AM   #1
ubuntuv
Member
 
Registered: Jan 2010
Posts: 71

Rep: Reputation: 0
Change mac address to multicast mac address


Hi,

For some experimental purpose, I like to change the mac address of an interface to multicast mac address. But linux kernel is not allowing. I am using Fedora Core 19.

Quote:
$sudo macchanger --mac=3F:29:8f:70:00:68 enp0s20u4
Current MAC: 34:29:8f:70:00:68 (unknown)
Permanent MAC: 34:29:8f:70:00:69 (unknown)
[ERROR] Could not change MAC: interface up or insufficient permissions: Cannot assign requested address
Please tell some technique to override this. Thanks in advance.

Regards,
uv
 
Old 01-15-2019, 11:40 AM   #2
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 23,509

Rep: Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735
Quote:
Originally Posted by ubuntuv View Post
Hi,
For some experimental purpose, I like to change the mac address of an interface to multicast mac address. But linux kernel is not allowing. I am using Fedora Core 19.
Code:
$sudo macchanger --mac=3F:29:8f:70:00:68 enp0s20u4
Current MAC: 34:29:8f:70:00:68 (unknown)
Permanent MAC: 34:29:8f:70:00:69 (unknown)
[ERROR] Could not change MAC: interface up or insufficient permissions: Cannot assign requested address
Please tell some technique to override this. Thanks in advance.
You've been using Linux for eight years now, based on your LQ history. And you've been told about sudo before, too....your error is VERY obvious; you're running that command as a regular user, not root/sudo.
 
Old 01-15-2019, 02:04 PM   #3
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 16,858
Blog Entries: 10

Rep: Reputation: 5012Reputation: 5012Reputation: 5012Reputation: 5012Reputation: 5012Reputation: 5012Reputation: 5012Reputation: 5012Reputation: 5012Reputation: 5012Reputation: 5012
strange, TB0ne, I can see the command starts with "sudo"?

anyhow, the error says "interface up or insufficient permissions" - maybe it's about the first case?
 
Old 01-15-2019, 03:28 PM   #4
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 23,509

Rep: Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735
Quote:
Originally Posted by ondoho View Post
strange, TB0ne, I can see the command starts with "sudo"?

anyhow, the error says "interface up or insufficient permissions" - maybe it's about the first case?
Indeed it does; I replied too quickly. Saw the "$" prompt with an "insufficient permissions" error. Still, though...Fedora 19?? It went EOL four years ago, so not surprised problems are coming up. Or that you can't change the MAC address of an interface that's already up.
 
Old 01-15-2019, 11:30 PM   #5
ubuntuv
Member
 
Registered: Jan 2010
Posts: 71

Original Poster
Rep: Reputation: 0
Hi,

I tried putting down the interface in root prompt. Other mac addresses work, but not the multicast ones.

Quote:
[root@svtstb2end1 network-scripts]# ifconfig enp0s20u4 down
[root@svtstb2end1 network-scripts]# macchanger --mac=3F:29:8f:70:00:68 enp0s20u4
Current MAC: 34:29:8f:70:00:68 (unknown)
Permanent MAC: 34:29:8f:70:00:69 (unknown)
[ERROR] Could not change MAC: interface up or insufficient permissions: Cannot assign requested address
[root@svtstb2end1 network-scripts]# macchanger --mac=32:29:8f:70:00:68 enp0s20u4
Current MAC: 34:29:8f:70:00:68 (unknown)
Permanent MAC: 34:29:8f:70:00:69 (unknown)
New MAC: 32:29:8f:70:00:68 (unknown)
Please suggest some solutions.

Thanks
uv.
 
Old 01-16-2019, 08:21 AM   #6
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 23,509

Rep: Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735Reputation: 6735
Quote:
Originally Posted by ubuntuv View Post
Hi,
I tried putting down the interface in root prompt. Other mac addresses work, but not the multicast ones.
Code:
[root@svtstb2end1 network-scripts]# ifconfig enp0s20u4 down
[root@svtstb2end1 network-scripts]# macchanger --mac=3F:29:8f:70:00:68 enp0s20u4
Current MAC: 34:29:8f:70:00:68 (unknown)
Permanent MAC: 34:29:8f:70:00:69 (unknown)
[ERROR] Could not change MAC: interface up or insufficient permissions: Cannot assign requested address
[root@svtstb2end1 network-scripts]# macchanger --mac=32:29:8f:70:00:68 enp0s20u4
Current MAC: 34:29:8f:70:00:68 (unknown)
Permanent MAC: 34:29:8f:70:00:69 (unknown)
New MAC: 32:29:8f:70:00:68 (unknown)
Please suggest some solutions.
Since you say it's for 'some experimental purpose', have you read about what those addresses are, and their limitations?? Or what the components of a MAC address are?
https://en.wikipedia.org/wiki/Multic...dress#Ethernet

Feel free to rewrite the kernel portions to remove the multicast limitations.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
MAC not blocked by router, can't connect to Internet unless I change MAC address? Brett Weiland Linux - Networking 2 10-30-2017 03:55 PM
Resident Multicast Sockets on a Multicast Router bryanj4 Linux - Networking 0 03-25-2015 01:45 AM
IPv6 multicast address used with VLC and multicast address routing merrittr Linux - Networking 2 01-28-2015 02:26 PM
IPv6 multicast listener on a Linux box acting as multicast router maxtux Linux - Networking 0 04-01-2012 10:52 AM
network load balancing & multicast mac-address isac.gnuton Linux - Networking 0 01-24-2007 05:11 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 04:48 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration