LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
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, 10:33 AM   #1
ubuntuv
Member
 
Registered: Jan 2010
Posts: 82

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, 10:40 AM   #2
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,753

Rep: Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983
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, 01:04 PM   #3
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 19,872
Blog Entries: 12

Rep: Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053
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, 02:28 PM   #4
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,753

Rep: Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983
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, 10:30 PM   #5
ubuntuv
Member
 
Registered: Jan 2010
Posts: 82

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, 07:21 AM   #6
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,753

Rep: Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983Reputation: 7983
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



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 02:55 PM
Resident Multicast Sockets on a Multicast Router bryanj4 Linux - Networking 0 03-25-2015 12:45 AM
IPv6 multicast address used with VLC and multicast address routing merrittr Linux - Networking 2 01-28-2015 01:26 PM
IPv6 multicast listener on a Linux box acting as multicast router maxtux Linux - Networking 0 04-01-2012 09:52 AM
network load balancing & multicast mac-address isac.gnuton Linux - Networking 0 01-24-2007 04:11 AM

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

All times are GMT -5. The time now is 10:14 PM.

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